Skip to content

Instantly share code, notes, and snippets.

@aortbals
Last active February 9, 2016 14:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aortbals/1eca995bb3645a0e6f4b to your computer and use it in GitHub Desktop.
Save aortbals/1eca995bb3645a0e6f4b to your computer and use it in GitHub Desktop.
React JSX Sublime Text Snippets
<snippet>
<content><![CDATA[
import React, { Component } from 'react';
export default class ${TM_FILENAME/(.?\w*)(?:\.\w+)*$/$1/g} extends Component {
static propTypes = {
};
render() {
return (
$1
);
}
}
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>rce</tabTrigger>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<scope>source.js</scope>
<description>React: Component (ES6)</description>
</snippet>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment