Hi, in order to preloading a javascript file (before application.js) with jsbundling i need to add 2 tags
<%= preload_link_tag "something.js", as: "script" %>
<%= javascript_include_tag "something.js", "data-turbo-track": "reload" %>
If i used importmap, i just pin something.js
with preload: true
.
So in my point of view, it’s nice if we could add param preload
to javascript_include_tag
or we could create new helper tag like preload_javascript_tag
to combine 2 above tags.
what do you think ?
thanks!