Not seen any information in the documentation, but is there an additional process to include files the ‘scripts/autoload’ folder?
I’ve followed suit and name it with an underscrore, but whether I do that or not, files are not being included in main.js.
I have a script called megamenu.js.
Added to /assets/scripts/autoload/_megamenu.js
I then yarn run build. Compiled fine, but the content of the script don’t get included anywhere.
Do I need to add this somewhere else to get it included inside the /autoload/ folder?
If I add import “./autoload/_megamenu.js”; to main.js then it gets included, but is the right method? I have around 20 js files to include and wondered if thats the best way to include them all (separate imports for each)?
Any help would be appreciated.