You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+20-13Lines changed: 20 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,24 +15,29 @@ leaving Webpack responsible solely for app-like JavaScript, or it can be used ex
15
15
16
16
**NOTE:** The master branch now hosts the code for v6.x.x. Please refer to [5-x-stable](https://github.com/rails/webpacker/tree/5-x-stable) branch for 5.x documentation.
17
17
18
+
Visit [Shipping Webpacker v6 – Status](https://discuss.rubyonrails.org/t/shipping-webpacker-v6-status/79683) for the latest news on a v6 release.
19
+
18
20
Pleaes see the [new rails/webpacker discussion forum](https://discuss.rubyonrails.org/c/webpacker/10) to discuss debugging and troubleshooting tips. Please open issues for bugs and feature requests.
19
21
20
22
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
21
23
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
@@ -80,19 +85,21 @@ Pleaes see the [new rails/webpacker discussion forum](https://discuss.rubyonrail
80
85
81
86
## Installation
82
87
83
-
You can configure a new Rails application with Webpacker right from the start using the `-j webpack` option:
84
-
85
-
With Rails v7:
88
+
### Rails v6
89
+
With Rails v6, webpacker is installed by default:
86
90
```bash
87
-
rails new myapp -j webpack
91
+
rails new myapp
88
92
```
89
93
90
-
With Rails v6:
94
+
### Rails v7
95
+
96
+
With Rails v7, skip JavaScript for a new app and follow below Manual Installation Steps to manually add the `webpacker` gem to your Gemfile.
91
97
```bash
92
-
rails new myapp
98
+
rails new myapp --skip-javascript
93
99
```
94
100
95
-
Or you can add it later by changing your `Gemfile`:
101
+
### Manual Installation Steps
102
+
Update your `Gemfile`:
96
103
97
104
```ruby
98
105
# Gemfile
@@ -113,10 +120,10 @@ Then running the following to install Webpacker:
113
120
When `package.json` and/or `yarn.lock` changes, such as when pulling down changes to your local environment in a team settings, be sure to keep your NPM packages up-to-date:
114
121
115
122
```bash
116
-
yarn install
123
+
yarn
117
124
```
118
125
119
-
###Usage
126
+
## Usage
120
127
121
128
Once installed, you can start writing modern ES6-flavored JavaScript apps right away:
0 commit comments