I am new to rails 7 and dont know where to put my custom js files. Now I know the importmaps are used to get third part javascript libraries via cdn's and we include in our application.js file. But suppose if I have my custom js files which are shared across multiple views, then in asset pipeline, I used to put them in app/assets/javascripts and if using webpacker, used to keep in app/javascript and then arrange accordingly with pack tags or include tags. But here using importmaps, where should I put these custom js files as importmaps are just for third party js libraries
Asked
Active
Viewed 38 times
0
-
1https://stackoverflow.com/a/72855705/207090 – Alex Jul 16 '23 at 23:27
-
You can check out Stimulus Controllers [here](https://stimulus.hotwired.dev/reference/controllers) – crodev Jul 17 '23 at 14:24