Skip to content

Commit c02e648

Browse files
committed
add linking javascript pack to readme
1 parent 24d8885 commit c02e648

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,13 @@ This gives you:
7272
- [`ReactRailsUJS`](#ujs) setup in `app/javascript/packs/application.js`
7373
- `app/javascript/packs/server_rendering.js` for [server-side rendering](#server-side-rendering)
7474

75+
Link the JavaScript pack in Rails view using `javascript_pack_tag` [helper](https://github.com/rails/webpacker#usage), for example:
76+
77+
```
78+
<!-- application.html.erb -->
79+
<%= javascript_pack_tag 'application' %>
80+
```
81+
7582
Generate your first component:
7683

7784
```

0 commit comments

Comments
 (0)