Open michaelKurowski opened 5 years ago
I met yesterday gulp.js and I think that it might be right tool to perfrom those actions. I mean watching backend/frontend files and refresh whole app if it's neccessary. Maybe you got some ideas to other solutions ?
I think that webpack has an already optimized implementation of watching files. But it requires more research and possibly benchmarks comparison.
We need a build system that rebuilds backend or frontend in case if any changes occurred there. As for now, a developer might not remember to refresh/rebuild the app after making changes, and face with some problems during debugging caused by the fact that He website that he's viewing is still an old version of his app. It can add additional hours and frustration to the debugging process.
The task can be divided into 2 parts: 1) Frontend watcher As for now, once a developer performs a change in frontend database (
src/server/frontEnd
), He needs to manually runnpm run build-dev
to rebuild the app. We need a watcher that rebuilds the frontend when any of frontend files have been modified. As far as I remember, it should be possible to do with webpack, but the person that'll be taking care of this ticket will need to investigate is further as I don't remember the details.2) Backend watcher Similiar to 1), when developer performs change in backend files (
src/server
, excludingsrc/server/frontEnd
) then He needs to kill currently running LokIM server, and runnpm start
. Not sure with webpack, as we mainly use it to bundle frontend files, but nodemon should be helpful here.User story
WARNING!!! The file watchers tend to be very resources-draining, and thus the person assigned to this task should find a solution that will be really optimized, to not slowdown another developer's machine.
Progress 1) - [ ] I've investigated the best way to perform the task 2) - [ ] I've implemented backend watcher 3) - [ ] I've implemented frontend watcher