ctrl+shift+p filters: :st2 :st3 :win :osx :linux
Browse

React​JS

by facebookarchive ALL Top 100

Sublime Text helpers for React. Syntax highlighting DEPRECATED in favor of babel/babel-sublime

Details

  • 2015.05.11.19.44.00
  • github.​com
  • github.​com
  • 9 years ago
  • 1 hour ago
  • 11 years ago

Installs

  • Total 251K
  • Win 113K
  • Mac 98K
  • Linux 40K
Oct 22 Oct 21 Oct 20 Oct 19 Oct 18 Oct 17 Oct 16 Oct 15 Oct 14 Oct 13 Oct 12 Oct 11 Oct 10 Oct 9 Oct 8 Oct 7 Oct 6 Oct 5 Oct 4 Oct 3 Oct 2 Oct 1 Sep 30 Sep 29 Sep 28 Sep 27 Sep 26 Sep 25 Sep 24 Sep 23 Sep 22 Sep 21 Sep 20 Sep 19 Sep 18 Sep 17 Sep 16 Sep 15 Sep 14 Sep 13 Sep 12 Sep 11 Sep 10 Sep 9 Sep 8 Sep 7
Windows 1 6 1 0 4 6 0 3 3 3 4 2 1 4 2 2 2 2 1 4 4 2 5 5 2 2 1 5 1 3 1 2 3 7 1 3 4 2 1 2 5 8 5 4 2 5
Mac 0 2 0 2 5 2 1 0 1 0 2 5 3 0 2 2 1 1 1 4 1 2 2 0 0 1 0 1 0 3 2 0 2 1 3 0 1 0 0 0 3 1 1 3 1 0
Linux 0 2 0 2 2 0 0 2 1 1 0 0 2 0 4 1 1 1 5 2 0 0 0 0 2 1 1 0 1 2 1 4 3 1 1 3 3 4 2 2 3 0 1 2 0 1

Readme

Source
raw.​githubusercontent.​com

sublime-react

Snippets for ReactJS. This package used to provide JSX syntax highlighting and has been DEPRECATED in favor of babel/babel-sublime.

alt tag

Installation

Install the React package via Sublime's Package Manager

You will need the Sublime Package Manager.

  • Open the command palette: ⌘+shift+p on MacOS/Linux, ctrl+shift+p on Windows

  • type install, select Package Control: Install Package

  • type React, select ReactJS

Usage

Syntax highlighting

Syntax highlighting is no longer provided by this packages. We recommend that you use (babel-sublime) instead.

Snippets

It's easy! Simply activate snippets by typing a mnemonic followed by TAB.

alt tag

Snippets are available for both JSX and CJSX (React CoffeeScript).

Documentation of available snippets (JSX):

cdm→  componentDidMount: fn() { ... }

   cdup→  componentDidUpdate: fn(pp, ps) { ... }

     cs→  var cx = React.addons.classSet;

    cwm→  componentWillMount: fn() { ... }

    cwr→  componentWillReceiveProps: fn(np) { ... }

    cwu→  componentWillUpdate: fn(np, ns) { ... }

   cwun→  componentWillUnmount: fn() { ... }

     cx→  cx({ ... })

    fdn→  React.findDOMNode(...)

    fup→  forceUpdate(...)

    gdp→  getDefaultProps: fn() { return {...} } 

    gis→  getInitialState: fn() { return {...} } 

    ism→  isMounted()

  props→  this.props.

     pt→  propTypes { ... }

    rcc→  component skeleton

   refs→  this.refs.

    ren→  render: fn() { return ... }

    scu→  shouldComponentUpdate: fn(np, ns) { ... }

    sst→  this.setState({ ... })

  state→  this.state.

Contributing

Rebuilding the docs

After making changes to snippet files, run npm install && npm run build-docs to automatically generate this document from source. Do not make changes to README.md directly.

Contributor License Agreement

Contributions are very welcome, but we ask that you please fill out our CLA in order for us to accept your pull request.