Answer the question
In order to leave comments, you need to log in
How to make code from application.js run before code from .html.slim files in Rails 7?
Used importmaps, made pin jquery, in application.js did:
import jquery from 'jquery';
window.$ = jquery;
h1 Hello
javascript:
$('h1').hide();
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question