chaynHQ / soulmedicine

Soul Medicine a multilingual digital service designed to deliver critical safety information and supportive messaging in bite-sized pieces.
https://soulmedicine.io
MIT License
37 stars 9 forks source link

Migrate from JS build system from webpacker and shakapacker #337

Closed tarebyte closed 1 year ago

tarebyte commented 1 year ago

This migrates the JS build system from Rails Webpacker (now retired) to Shakapacker the "Official, actively maintained successor to rails/webpacker".

While attempting to migrate to Node LTS (18) I was having issues with Webpack 4. By moving to Shakapacker we are able to use Webpack 5 which is the latest release.

I did not update any of the dependencies that weren't related to the build system. That will be it's own set of PRs.

The one side effect of this change is that we're now building on ES2015 instead of ES5. Which means we've gone from 98.4% browser compatibility to 97.24%.

I'd love feedback if this is acceptable before shipping. If we want to target ES5 then we can update the .browerslistrc to be more compatible. I think it would depend on what the Google Analytics say.

eleanorreem commented 1 year ago

Hey @tarebyte, I am totally fine with 97% browser compatibility. We don't currently have a minimum support requirement for browsers. We're hoping to set that soon. Huge thanks for this