An Atom snippet library for Metal.js, and metal-css-transitions. This library uses ES6 syntax.
Install via apm install atom-metal-snippets
import Transition from 'metal-css-transitions';
import Component from 'metal-jsx';
import ${1} from 'metal-redux';
import Component from 'metal-soy';
import Component, {Config} from 'metal-soy';import templates from './${1:MyComponent}.soy';class ${1:MyComponent} extends Component {${2:}}${1:MyComponent}.STATE = {};Soy.register(${1:MyComponent}, templates);export default ${1:MyComponent};
this.${1} = this.${1}.bind(this);
import Component, {Config} from 'metal-jsx';class ${1:MyComponent} extends Component {render() {return (${2:<div>MyComponent</div>});}}${1:MyComponent}.PROPS = {};${1:MyComponent}.STATE = {};export default ${1:MyComponent};
<Transition name="$1">${2}</Transition>
attached() {${1}}
created() {${1}}
detached() {${1}}
disposed() {${1}}
render() {return (${2});}
rendered() {${1}}
shouldUpdate(newState, newProps) {${1}}
sync$1(newVal, prevVal) {${2}}
this.setState({$1});
${1}.PROPS = {${2}};
${1}.STATE = {${2}};
Config.any()
Config.conarr()
Config.arrayOf(${1})
Config.bool()
Config.func()
Config.instanceOf(${1})
Config.number()
Config.object()
Config.objectOf(${1})
Config.oneOfType([${1},])
Config.shapeOf({${1}})
Config.string()
Config.value(${1})
Good catch. Let us know what about this package looks wrong to you, and we'll investigate right away.