Hey guys,
first of all, thanks for that great project. I'm using my Pi with the standard image to show the web theme dubbadhar on it.
I already did some changes to the theme and it worked fine so far. I changed some stuff inside the index and the theme-config.json.
But when I tried to change anything inside the script.js it would not work. Non of the changes have any effect. It actually seems like that the whole file is not even beeing read. I've deleted it, and the whole server is still running fine.
I tried everything to delet caches and so on in the browser and in windows (in the AppData/Roaming folder). Nothing is working. There seems to be something wrong with the webserver you're using.
My file setup at the moment is that the only files of the dubbadhar theme exist in the AppData\Local\MoBro\app-1.0.0-beta2\resources\resources\public\theme\dubbadhar folder.
I tried putting stuff in the MoBro_local folder but that didnt help. It just put more confusion to it, as the index was loaded from MoBro_local folder but the theme-config.json was loaded from the MoBro folder.
Do you have any idea where there could be a caching problem. Or is there anything else I'm missing here?
Thanks.
Oh, and of course I'm talking about the script.js in the /scr/js folder.
Hey @eiMer,
I think I know what your problem is. The dubbadhar theme actually is compiled beforehand. There is a webpack.config.js file in there that is used to bundle everything together that is in the /src directory of the theme. The script.js is actually served out of the /dist folder.
I think best would be that you copy the whole theme to your MoBro_Local folder and then do the following things (be careful not override the changes that you already did)
- Ensure that you have node and npm installed (otherwise install it from here https://nodejs.org/en/)
- Run “npm install” in the dubbadhar theme folder that you copied to MoBro_Local to install everything that is necessary
- Run “npm run build” to bundle everything to the /dist directory
- You can also use “npm run dev” which will keep the process running and watches for further changes, so that you don't have to run “npm run build” every single time
Thanks Dave, it worked! :)