0 votes
in JUnit by

If the Rails asset pipeline is being used to serve JavaScript files, how would you include a link to one of those JavaScript files in a view?

a. <script src="/main.js"></script>

b. <%= javascript_include_tag 'main' %>

c. <%= javascript_tag 'main' %>

d. <!-- include_javascript 'main' -->

1 Answer

0 votes
by

If the Rails asset pipeline is being used to serve JavaScript files, how would you include a link to one of those JavaScript files in a view?

a. <script src="/main.js"></script>

b. <%= javascript_include_tag 'main' %>

c. <%= javascript_tag 'main' %>

d. <!-- include_javascript 'main' -->

Correct answer is :-  <%= javascript_include_tag 'main' %>

...