@samitouri / QOS-React-2 / commits / 7a2be27d63

semicolon cleanup

One unnecessary semicolon removed and few missing added.

Bartosz Kaszubowski committed Jul 5, 2015 at 01:06 UTC 7a2be27d63d669c1a1e27c99346fb7daaf13322b
2 files changed +16 -16
src/isomorphic/modern/class/__tests__/ReactTypeScriptClass-test.ts
+15 -15
@@ -24,7 +24,7 @@ class Inner extends React.Component {
24 renderedName = this.props.name;
25 return React.createElement('div', { className: this.props.name });
26 }
27 -};
27 +}
28
29 function test(element, expectedTag, expectedClassName) {
30 var instance = React.render(element, container);
@@ -83,11 +83,11 @@ class StateBasedOnContext extends React.Component {
83 static contextTypes = {
84 tag: React.PropTypes.string,
85 className: React.PropTypes.string
86 - }
86 + };
87 state = {
88 tag: this.context.tag,
89 className: this.context.className
90 - }
90 + };
91 render() {
92 var Tag = this.state.tag;
93 return React.createElement(Tag, {className: this.state.className});
@@ -98,7 +98,7 @@ class ProvideChildContextTypes extends React.Component {
98 static childContextTypes = {
99 tag: React.PropTypes.string,
100 className: React.PropTypes.string
101 - }
101 + };
102 getChildContext() {
103 return { tag: 'span', className: 'foo' };
104 }
@@ -112,7 +112,7 @@ var renderCount = 0;
112 class RenderOnce extends React.Component {
113 state = {
114 bar: this.props.initialValue
115 - }
115 + };
116 componentWillMount() {
117 this.setState({ bar: 'bar' });
118 }
@@ -124,19 +124,19 @@ class RenderOnce extends React.Component {
124
125 // it should throw with non-object in the initial state property
126 class ArrayState {
127 - state = ['an array']
127 + state = ['an array'];
128 render() {
129 return React.createElement('span');
130 }
131 }
132 class StringState {
133 - state = 'a string'
133 + state = 'a string';
134 render() {
135 return React.createElement('span');
136 }
137 }
138 class NumberState {
139 - state = 1234
139 + state = 1234;
140 render() {
141 return React.createElement('span');
142 }
@@ -144,7 +144,7 @@ class NumberState {
144
145 // it should render with null in the initial state property
146 class NullState extends React.Component {
147 - state = null
147 + state = null;
148 render() {
149 return React.createElement('span');
150 }
@@ -154,10 +154,10 @@ class NullState extends React.Component {
154 class BoundEventHandler extends React.Component {
155 state = {
156 bar: this.props.initialValue
157 - }
157 + };
158 handleClick = () => {
159 this.setState({ bar: 'bar' });
160 - }
160 + };
161 render() {
162 return (
163 React.createElement(Inner, {
@@ -172,7 +172,7 @@ class BoundEventHandler extends React.Component {
172 class UnboundEventHandler extends React.Component {
173 state = {
174 bar: this.props.initialValue
175 - }
175 + };
176 handleClick() {
177 this.setState({ bar: 'bar' });
178 }
@@ -185,7 +185,7 @@ class UnboundEventHandler extends React.Component {
185
186 // it renders using forceUpdate even when there is no state
187 class ForceUpdateWithNoState extends React.Component {
188 - mutativeValue : string = this.props.initialValue
188 + mutativeValue : string = this.props.initialValue;
189 handleClick() {
190 this.mutativeValue = 'bar';
191 this.forceUpdate();
@@ -203,8 +203,8 @@ class ForceUpdateWithNoState extends React.Component {
203 // it will call all the normal life cycle methods
204 var lifeCycles = [];
205 class NormalLifeCycles {
206 - props : any
207 - state = {}
206 + props : any;
207 + state = {};
208 componentWillMount() {
209 lifeCycles.push('will-mount');
210 }
src/test/ReactTestUtils.js
+1 -1
@@ -42,7 +42,7 @@ function findAllInRenderedTreeInternal(inst, test) {
42 if (!inst || !inst.getPublicInstance) {
43 return [];
44 }
45 - var publicInst = inst.getPublicInstance()
45 + var publicInst = inst.getPublicInstance();
46 var ret = test(publicInst) ? [publicInst] : [];
47 if (ReactTestUtils.isDOMComponent(publicInst)) {
48 var renderedChildren = inst._renderedChildren;