How to handle different configurations for each module using Nestjs Config

Viewed 99
1 Answers

I don't fully understand why you need such behaviour, and maybe with more information I could give you a more detailed input. However, from the information you provided, I would suggest to keep the configuration variables globally scoped and avoid name collisions, not only for design purposes but for readability also. If you have a lot of configuration variables, you can always separate them into different JSON files and load them from each module, but naming them differently. Let me know if this is a viable solution for your problem.

Related