rax-snippets
Snippets
Snippet |
Renders |
imc |
Import Rax |
imcc |
Import Rax / Component |
imv |
Import View |
imt |
Import Text |
ima |
Import All |
cc |
Class Component |
rct |
Class Component Template |
rft |
Function Component Template |
hoc |
Higher Order Component |
view |
view tag |
text |
text tag |
Full Expansions
imc - Import Rax
import { createElement } from 'rax';
imcc - Import rax, Component
import { createElement, Component } from 'rax';
imv - Import View
import View from 'rax-view';
imt - Import Text
import Text from 'rax-text';
ima - Import All
import { createElement, Component } from 'rax';
import Text from 'rax-text';
import View from 'rax-view';
cc - Class Component
class | extends Component {
state = { | },
render() {
return ( | );
}
}
export default |;
rct - Class Component Template
import { createElement, Component } from 'rax';
import Text from 'rax-text';
import View from 'rax-view';
class | extends Component {
state = { | }
render() {
return ( | );
}
}
export default |;
rft - Function Component Template
import { createElement } from 'rax';
import Text from 'rax-text';
import View from 'rax-view';
function |() {
return ( | );
}
export default |;
hoc - Higher Order Component
function | (|) {
return class extends Component {
constructor(props) {
super(props);
}
render() {
return < | {...this.props} />;
}
};
}
view - View
<View></View>
text - Text
<Text></Text>