Skip to content

Commit

Permalink
Merge pull request #29342 from koic/change_application_js_included_in…
Browse files Browse the repository at this point in the history
…_rails_app

Change default application.js included in new Rails app [ci skip]
  • Loading branch information
matthewd committed Jun 3, 2017
2 parents c10f4ff + 116b70c commit ab4f811
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions guides/source/asset_pipeline.md
Original file line number Diff line number Diff line change
Expand Up @@ -447,15 +447,15 @@ For example, a new Rails application includes a default

```js
// ...
//= require jquery
//= require jquery_ujs
//= require rails-ujs
//= require turbolinks
//= require_tree .
```

In JavaScript files, Sprockets directives begin with `//=`. In the above case,
the file is using the `require` and the `require_tree` directives. The `require`
directive is used to tell Sprockets the files you wish to require. Here, you are
requiring the files `jquery.js` and `jquery_ujs.js` that are available somewhere
requiring the files `rails-ujs.js` and `turbolinks.js` that are available somewhere
in the search path for Sprockets. You need not supply the extensions explicitly.
Sprockets assumes you are requiring a `.js` file when done from within a `.js`
file.
Expand Down

0 comments on commit ab4f811

Please sign in to comment.