-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Status #2
Comments
I'm not sure if this works with jspm 17. I don't really plan on supporting this much further, as @gaearon is planning a different approach for the future which looks like it will work with jspm 17's hmr. |
I don’t know much about jspm but I want to support it right in React Hot Loader 3 if possible. But for this, I need somebody to help with looking at my approach and figuring out what needs to be done to have support for jspm as well. |
I can confirm this one works... Also I actually think you can directly use @gaearon 's |
@gaearon I'm interested in getting a jspm working properly with hot reloading. So I can give some limited time into this. I just got RedBox and hmr working with jspm |
Basically the approach I’m taking in RHL3 is to tag any exported function with a
|
@gaearon Specifically on react exports? |
Preferably but this really doesn’t matter because the transform is not React-specific. There’s no harm in putting |
In other words, doing it for all exported functions is fine. |
It looks like the same approach as |
If so, I think we’d like to keep this in the RHL repo. I’m leaning towards a monorepo because I’m tired of issues scattered across semi-related projects. |
I would also specifically leave out the webpack specific hot variable. |
What |
Oh, the new version won’t be using The new Babel plugin (it’s not written yet) will do exactly what the new Webpack plugin does: tag every exported function with In case of Webpack, the consumer would need to use HMR API directly. I presume jspm has something similar, if it’s not called |
@gaearon I'm currently converting Is there another issue we can take this discussion to? |
gaearon/react-hot-boilerplate#61? This is where it’s going. |
Looks good. Basically jspm doesn't have any hmr system at the moment. However a lot of people are using https://github.com/capaj/systemjs-hot-reloader. The approch is basically to:
I have a feeling @guybedford is going to build this into systemjs? @tyscorp RedBox works :D So you can include it in your boilerplate: SystemJS.config({
transpiler: "plugin-babel",
meta: {
"*.js": {
"babelOptions": {
"stage1": true,
"plugins": [
[
"react-transform",
{
"transforms": [
{
"transform": "react-transform-jspm-hmr"
},
{
"transform": "react-transform-catch-errors",
"imports": [
"react",
"redbox-react"
]
}
]
}
]
]
}
}
}
... |
@alexisvincent great to hear you're thinking through this stuff. Just let me know if there is anything I can do to assist here. |
Whats the status on this? Does it work in jspm 17?
The text was updated successfully, but these errors were encountered: