Skip to content
This repository was archived by the owner on Jan 13, 2022. It is now read-only.

Commit c0f9a4b

Browse files
author
Yang Su
committed
Added snippet for context
1 parent acf6dec commit c0f9a4b

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@ Snippets are available for both JSX and CJSX ([React CoffeeScript](https://githu
3939
4040
cs→ var cx = React.addons.classSet;
4141
42+
ctx→ this.context.
43+
4244
cwm→ componentWillMount: fn() { ... }
4345
4446
cwr→ componentWillReceiveProps: fn(np) { ... }
@@ -53,9 +55,9 @@ Snippets are available for both JSX and CJSX ([React CoffeeScript](https://githu
5355
5456
fup→ forceUpdate(...)
5557
56-
gdp→ getDefaultProps: fn() { return {...} }
58+
gdp→ getDefaultProps: fn() { return {...} }
5759
58-
gis→ getInitialState: fn() { return {...} }
60+
gis→ getInitialState: fn() { return {...} }
5961
6062
ism→ isMounted()
6163
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<snippet>
2+
<content><![CDATA[
3+
this.context.${1}
4+
]]></content>
5+
<tabTrigger>ctx</tabTrigger>
6+
<scope>source.js</scope>
7+
<description>React: this.context.</description>
8+
</snippet>

0 commit comments

Comments
 (0)