Skip to content
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

React on Rails with Webpacker -- Work to do #786

Closed
justin808 opened this issue Mar 31, 2017 · 2 comments
Closed

React on Rails with Webpacker -- Work to do #786

justin808 opened this issue Mar 31, 2017 · 2 comments

Comments

@justin808
Copy link
Member

justin808 commented Mar 31, 2017

Please don’t be shy to comment!

Summary

Webpacker has a few key things for React on Rails (and many things that don’t matter)

  1. Rails helpers to get the right asset path, be it:

    1. Dev static file

    2. Dev hot path

    3. Production path

  2. Webpack v2 example of using the Manifest Plugin which is the secret sauce of going from the base filename to maybe the hashed file name for production

  3. The ability to configure the directories to match the React on Rails standards of putting all client files, including node_modules in the /client directory

Prototype

  • Use the basic React on Rails generator and write down the steps to migrate the app to Webpacker. This can form the basis of the upgrade docs, as existing apps won’t be running the generator.

Change Rake Task for precompile

  • Automatically inserted now

  • Want to use the default webpacker one

Change Generators

Generator code is here

List steps

Test Helper integration

See RSpec Configuration

Doc Changes

Questions

  1. What is needed to support the old way (asset pipeline) to coexist with the new way?

  2. Should the 7.0 update require the new way of using webpacker? This will depend on how much work the migration is.

@justin808
Copy link
Member Author

CC: @kaizencodes

@justin808
Copy link
Member Author

This was done for React on Rails v9.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant