react-hot-loader
Advanced tools
Comparing version 0.1.2 to 0.1.3
/** @jsx React.DOM */ | ||
var React = require('react'), | ||
B = require('react-hot!./b'); | ||
B = require('./b'); | ||
@@ -6,0 +6,0 @@ var A = React.createClass({ |
/** @jsx React.DOM */ | ||
var React = require('react'), | ||
A = require('react-hot!./a'); | ||
A = require('./a'); | ||
React.renderComponent(<A />, document.body); |
@@ -18,5 +18,5 @@ var path = require('path'); | ||
loaders: [ | ||
{ test: /\.jsx$/, loader: 'jsx-loader' } | ||
{ test: /\.jsx$/, loaders: ['react-hot', 'jsx-loader'] } | ||
] | ||
} | ||
}; |
@@ -15,9 +15,9 @@ module.exports = function () {}; | ||
'if (module.hot) {', | ||
' module.hot.accept(' + JSON.stringify('replaceCreateClass!' + moduleRequest) + ', function() {', | ||
' module.exports = require(' + JSON.stringify('replaceCreateClass!' + moduleRequest) + ')(createHotClass);', | ||
' module.hot.accept(' + JSON.stringify('!!replaceCreateClass!' + moduleRequest) + ', function() {', | ||
' module.exports = require(' + JSON.stringify('!!replaceCreateClass!' + moduleRequest) + ')(createHotClass);', | ||
' HotUpdateMixin.acceptUpdate(module.exports);', | ||
' });', | ||
'}', | ||
'module.exports = require(' + JSON.stringify('replaceCreateClass!' + moduleRequest) + ')(createHotClass);' | ||
'module.exports = require(' + JSON.stringify('!!replaceCreateClass!' + moduleRequest) + ')(createHotClass);' | ||
].join('\n'); | ||
}; |
{ | ||
"name": "react-hot-loader", | ||
"version": "0.1.2", | ||
"version": "0.1.3", | ||
"description": "Webpack loader that enables live-editing React components without unmounting or losing their state", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -42,4 +42,16 @@ # react-hot-loader | ||
You can also specify loader in config before `jsx-loader`: | ||
```javascript | ||
module: { | ||
loaders: [ | ||
{ test: /\.jsx$/, loaders: ['react-hot', 'jsx-loader'] } | ||
] | ||
} | ||
``` | ||
This will enable hot reload for all JSX files. | ||
# License | ||
MIT (http://www.opensource.org/licenses/mit-license.php) |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6695
57