I am interested in best practice and would like to know how I add configurable values when using nopCommerce?
In a standard MVC application I would add these to appsetting.json or web.config, how do I do this when using nopcommerce? (I'm hoping the answer is not putting something into the database)
Adding configurable values in appsettings.json for plugin is very bad idea. You should add appsettings.json file to your plugin. Create nop startup class (INopStartup) and load the values at startup time.
Plugin configure values should be saved in settings. That's the best practice. If you save values in appsettings.json or something like this files, you cannot change those unless you can access the server.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.