jedireza / hapi-react-views

:package: A hapi view engine for React components
MIT License
231 stars 33 forks source link

Isomorphic Hot Reload Question #25

Closed hydrotik closed 8 years ago

hydrotik commented 9 years ago

Sorry to bother again, but is there any support for hot module reloading of serve side components? Not sure if this would be done through hapi-react-views but my client side code is reloading but not the server. Also adding nodemon seems to create a lot of extra emissions versus running the server with just node. Haven't found any info on this anywhere but if it's possible having an example here would be very helpful.

jedireza commented 9 years ago

Thanks for opening an issue. It's no bother.

We do have a removeCache option you can pass, which should be defaulted to true during development. The literal default is 'production' !== process.env.NODE_ENV. This removes components from the require cache, so if you make changes, the next time you render the view we should see the changes without restarting the server.

Also adding nodemon seems to create a lot of extra emissions...

I'm not sure what you mean by that.