README.md in shakapacker-6.0.0.rc.14 vs README.md in shakapacker-6.0.0

- old
+ new

@@ -59,10 +59,11 @@ - [Custom Rails environments](#custom-rails-environments) - [Upgrading](#upgrading) - [Paths](#paths) - [Additional paths](#additional-paths) - [Deployment](#deployment) +- [Example Apps](#example-apps) - [Troubleshooting](#troubleshooting) - [Contributing](#contributing) - [License](#license) <!-- END doctoc generated TOC please keep comment here to allow auto update --> @@ -94,18 +95,26 @@ - React ## Installation ### Rails v6 -With Rails v6, webpacker is installed by default: +With Rails v6, [rails/webpacker v5](https://github.com/rails/webpacker/tree/5-x-stable) is installed by default: ```bash rails new myapp ``` +If you wish to migrate to Shakapacker, please follow the [V6 Upgrade](./docs/v6_upgrade.md) instructions. + +Alternatively, you can skip the default webpacker installation and then follow the [Manual Installation Steps](#manual-installation-steps) below. + +```bash +rails new myapp --skip-javascript +``` + ### Rails v7 -With Rails v7, skip JavaScript for a new app and follow below Manual Installation Steps to manually add the `webpacker` gem to your Gemfile. +With Rails v7, skip JavaScript for a new app and follow below Manual Installation Steps to manually add the `shakapacker` gem to your Gemfile. ```bash rails new myapp --skip-javascript ``` ### Manual Installation Steps @@ -296,11 +305,11 @@ **Note:** Don't forget to prefix `ruby` when running these binstubs on Windows ### Webpack Configuration -Webpacker gives you a default configuration file for your test, development, and production environments in `config/webpack/*.js`. +Webpacker gives you a default configuration file for your test, development, and production environments in `config/webpack/*.js`. By default, you don't need to make any changes to `config/webpack/webpack.config.js` files since it's all standard production-ready configuration. However, if you do need to customize or add a new loader, this is where you would go. Here is how you can modify webpack configuration: @@ -584,11 +593,11 @@ You can run following commands to upgrade Webpacker to the latest stable version. This process involves upgrading the gem and related JavaScript packages: ```bash # check your Gemfile for version restrictions -bundle update webpacker +bundle update shakapacker # overwrite your changes to the default install files and revert any unwanted changes from the install rails webpacker:install # yarn 1 instructions @@ -659,21 +668,21 @@ When compiling assets for production on a remote server, such as a continuous integration environment, it's recommended to use `yarn install --frozen-lockfile` to install NPM packages on the remote host to ensure that the installed packages match the `yarn.lock` file. If you are using a CDN setup, webpacker will use the configured [asset host](https://guides.rubyonrails.org/configuring.html#rails-general-configuration) value to prefix URLs for images or font icons which are included inside JS code or CSS. It is possible to override this value during asset compilation by setting the `WEBPACKER_ASSET_HOST` environment variable. +## Example Apps +* [React on Rails Tutorial With SSR, HMR fast refresh, and TypeScript](https://github.com/shakacode/react_on_rails_tutorial_with_ssr_and_hmr_fast_refresh) + ## Troubleshooting See the doc page for [Troubleshooting](./docs/troubleshooting.md). ## Contributing -[![Code Helpers](https://www.codetriage.com/shakacode/shakapacker/badges/users.svg)](https://www.codetriage.com/shakacode/shakapacker) - We encourage you to contribute to Webpacker! See [CONTRIBUTING](CONTRIBUTING.md) for guidelines about how to proceed. - ## License Webpacker is released under the [MIT License](https://opensource.org/licenses/MIT).