babel-plugin-react-import-extends
Version:
Write React Components without worrying to import React and extend component
28 lines (24 loc) • 321 B
JavaScript
class StatefulComponent {
componentDidMount() {
console.log('mounted')
}
render() {
return (
<div className="test">
Hello!
</div>
)
}
}
class Person {
constructor() {
this.name = 'vijay';
}
name() {
return this.name;
}
}
export {
StatefulComponent,
Person
}