Skip to content

Instantly share code, notes, and snippets.

@awinogradov
Last active June 19, 2018 14:47
Show Gist options
  • Save awinogradov/637e354bfb9eabb7072a6972b5707a8b to your computer and use it in GitHub Desktop.
Save awinogradov/637e354bfb9eabb7072a6972b5707a8b to your computer and use it in GitHub Desktop.
BRC deps
import Button from '../Button';
import Icon from '../Icon';
class CSelect {
public dependencies() {
return {
Icon,
Button
}
}
public render() {
const {Button, Icon} = this.dependencies();
return (<Button icon={<Icon type="load"/>}></Button>)
}
}
import CSelect from './Select';
import Button from '../Button@desktop';
class DSelect extends CSelect {
public dependencies() {
return {
...super.dependencies(),
Button
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment