: Environment specific client-side config file I'm developing a WebRTC app where the endpoints along with some other options are different for production and development. I was handed this project
I'm developing a WebRTC app where the endpoints along with some other options are different for production and development. I was handed this project so one of codebases uses Nodejs and the other uses plain html, css and js. I know that Nodejs has some modules that provide environment specific configs (e.g. Config) but they are all server-side.
My current solution is to have a config.js file in both branches which is statically served to the client. This however doesn't feel like best practice, and managing them with Git is pretty sketchy since I want the config.js file to be included in the repository but I don't want to have them changed when merging branches.
What are the most common ways to pass environment specific configuration options to the client in a web app?
More posts by @Cody1181609
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.