Skip to content

Commit 8123799

Browse files
knowbodymjackson
authored andcommitted
refactor imports
1 parent 73faa1f commit 8123799

File tree

12 files changed

+24
-24
lines changed

12 files changed

+24
-24
lines changed

examples/animations/app.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React from 'react'
2-
import ReactDOM from 'react-dom'
2+
import { render } from 'react-dom'
33
import ReactCSSTransitionGroup from 'react-addons-transition-group'
44
import { createHistory, useBasename } from 'history'
55
import { Router, Route, Link } from 'react-router'
@@ -50,7 +50,7 @@ class Page2 extends React.Component {
5050
}
5151
}
5252

53-
ReactDOM.render((
53+
render((
5454
<Router history={history}>
5555
<Route path="/" component={App}>
5656
<Route path="page1" component={Page1} />

examples/auth-flow/app.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React from 'react'
2-
import ReactDOM, { findDOMNode } from 'react-dom'
2+
import { render, findDOMNode } from 'react-dom'
33
import { Router, Route, Link, History } from 'react-router'
44
import { createHistory, useBasename } from 'history'
55
import auth from './auth'
@@ -124,7 +124,7 @@ function requireAuth(nextState, replaceState) {
124124
replaceState({ nextPathname: nextState.location.pathname }, '/login')
125125
}
126126

127-
ReactDOM.render((
127+
render((
128128
<Router history={history}>
129129
<Route path="/" component={App}>
130130
<Route path="login" component={Login} />

examples/dynamic-segments/app.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React from 'react'
2-
import ReactDOM from 'react-dom'
2+
import { render } from 'react-dom'
33
import { Router, Route, Link, Redirect } from 'react-router'
44
import { createHistory, useBasename } from 'history'
55

@@ -51,7 +51,7 @@ class Task extends React.Component {
5151
}
5252
}
5353

54-
ReactDOM.render((
54+
render((
5555
<Router history={history}>
5656
<Route path="/" component={App}>
5757
<Route path="user/:userID" component={User}>

examples/huge-apps/app.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*eslint-disable no-unused-vars */
22
import React from 'react'
3-
import ReactDOM from 'react-dom'
3+
import { render } from 'react-dom'
44
import { createHistory, useBasename } from 'history'
55
import { Router } from 'react-router'
66
import stubbedCourses from './stubs/COURSES'
@@ -24,7 +24,7 @@ const rootRoute = {
2424
} ]
2525
}
2626

27-
ReactDOM.render(
27+
render(
2828
<Router history={history} routes={rootRoute} />,
2929
document.getElementById('example')
3030
)

examples/master-detail/app.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React from 'react'
2-
import ReactDOM, { findDOMNode } from 'react-dom'
2+
import { render,} findDOMNode } from 'react-dom'
33
import { createHistory, useBasename } from 'history'
44
import { Router, History, Route, IndexRoute, Link } from 'react-router'
55
import ContactStore from './ContactStore'
@@ -156,7 +156,7 @@ var NotFound = React.createClass({
156156
}
157157
})
158158

159-
ReactDOM.render((
159+
render((
160160
<Router history={history}>
161161
<Route path="/" component={App}>
162162
<IndexRoute component={Index} />

examples/nested-animations/app.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React from 'react'
2-
import ReactDOM from 'react-dom'
2+
import { render } from 'react-dom'
33
import ReactCSSTransitionGroup from 'react-addons-transition-group'
44
import { createHistory, useBasename } from 'history'
55
import { Router, Route, Link } from 'react-router'
@@ -91,7 +91,7 @@ class Tab2 extends React.Component {
9191
}
9292
}
9393

94-
ReactDOM.render((
94+
render((
9595
<Router history={history}>
9696
<Route path="/" component={App}>
9797
<Route path="page1" component={Page1}>

examples/passing-props-to-children/app.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React from 'react'
2-
import ReactDOM from 'react-dom'
2+
import { render } from 'react-dom'
33
import { createHistory, useBasename } from 'history'
44
import { Router, Route, Link, History } from 'react-router'
55

@@ -79,7 +79,7 @@ const Taco = React.createClass({
7979
}
8080
})
8181

82-
ReactDOM.render((
82+
render((
8383
<Router history={history}>
8484
<Route path="/" component={App}>
8585
<Route path="taco/:name" component={Taco} />

examples/pinterest/app.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React from 'react'
2-
import ReactDOM from 'react-dom'
2+
import { render } from 'react-dom'
33
import { createHistory, useBasename } from 'history'
44
import { Router, Route, IndexRoute, Link } from 'react-router'
55

@@ -140,7 +140,7 @@ const Picture = React.createClass({
140140
}
141141
})
142142

143-
ReactDOM.render((
143+
render((
144144
<Router history={history}>
145145
<Route path="/" component={App}>
146146
<IndexRoute component={Index}/>

examples/query-params/app.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React from 'react'
2-
import ReactDOM from 'react-dom'
2+
import { render } from 'react-dom'
33
import { createHistory, useBasename } from 'history'
44
import { Router, Route, Link } from 'react-router'
55

@@ -37,7 +37,7 @@ class App extends React.Component {
3737
}
3838
}
3939

40-
ReactDOM.render((
40+
render((
4141
<Router history={history}>
4242
<Route path="/" component={App}>
4343
<Route path="user/:userID" component={User} />

examples/shared-root/app.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React from 'react'
2-
import ReactDOM from 'react-dom'
2+
import { render } from 'react-dom'
33
import { createHistory, useBasename } from 'history'
44
import { Router, Route, Link } from 'react-router'
55

@@ -74,7 +74,7 @@ class ForgotPassword extends React.Component {
7474
}
7575
}
7676

77-
ReactDOM.render((
77+
render((
7878
<Router history={history}>
7979
<Route path="/" component={App}>
8080
<Route component={SignedOut}>

0 commit comments

Comments
 (0)