forked from facebook/react
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Test 'create-react-class' with fixtures
NOTE: Never going to merge this commit, but I may cherry-pick it onto branches in order to test fixes for issue facebook#9765 **what is the change?:** Require and use the UMD bundles of 'create-react-class' in three fixtures to test the three supported uses; - test Global JS with globals.html - test AMD with requirejs.html - test CommonJS with webpack-alias **why make this change?:** To test facebook#9761 and other PRs fixing facebook#9765 **test plan:** Manual testing; - cd into the directory in fixtures - run the build step if needed - open the file **issue:** facebook#9765
- Loading branch information
Showing
6 changed files
with
91 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,25 @@ | ||
var React = require('react'); | ||
var ReactDOM = require('react-dom'); | ||
var createReactClass = require('create-react-class'); | ||
|
||
var Greeting = createReactClass({ | ||
render: function() { | ||
return React.createElement('H1', null, 'Hello' + this.props.name + '!!!!!'); | ||
} | ||
}); | ||
|
||
var CSSTransitionGroup = React.addons.CSSTransitionGroup; | ||
ReactDOM.render( | ||
React.createElement(CSSTransitionGroup, { | ||
transitionName: 'example', | ||
transitionAppear: true, | ||
transitionAppearTimeout: 500, | ||
transitionEnterTimeout: 0, | ||
transitionLeaveTimeout: 0, | ||
}, React.createElement('h1', null, | ||
'Hello World!' | ||
)), | ||
React.createElement( | ||
CSSTransitionGroup, | ||
{ | ||
transitionName: 'example', | ||
transitionAppear: true, | ||
transitionAppearTimeout: 500, | ||
transitionEnterTimeout: 0, | ||
transitionLeaveTimeout: 0 | ||
}, | ||
React.createElement(Greeting, {name: 'FOO'}) | ||
), | ||
document.getElementById('container') | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,25 @@ | ||
var React = require('react'); | ||
var CSSTransitionGroup = require('react-addons-css-transition-group'); | ||
var ReactDOM = require('react-dom'); | ||
var createReactClass = require('create-react-class'); | ||
|
||
var Greeting = createReactClass({ | ||
render: function() { | ||
return React.createElement('H1', null, 'Hello' + this.props.name + '!!!!!'); | ||
} | ||
}); | ||
|
||
ReactDOM.render( | ||
React.createElement(CSSTransitionGroup, { | ||
transitionName: 'example', | ||
transitionAppear: true, | ||
transitionAppearTimeout: 500, | ||
transitionEnterTimeout: 0, | ||
transitionLeaveTimeout: 0, | ||
}, React.createElement('h1', null, | ||
'Hello World!' | ||
)), | ||
React.createElement( | ||
CSSTransitionGroup, | ||
{ | ||
transitionName: 'example', | ||
transitionAppear: true, | ||
transitionAppearTimeout: 500, | ||
transitionEnterTimeout: 0, | ||
transitionLeaveTimeout: 0 | ||
}, | ||
React.createElement(Greeting, {name: 'FOO'}) | ||
), | ||
document.getElementById('container') | ||
); |