CodeIgniter Forums
Best Practices: Sharing a project - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28)
+--- Forum: CodeIgniter 4 Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=31)
+--- Thread: Best Practices: Sharing a project (/showthread.php?tid=75384)

Pages: 1 2


RE: Best Practices: Sharing a project - MGatner - 02-04-2020

Tatter\Settings is a port from my CI3 library and way predates this conversation, but I’m glad you found it. Smile I use that mostly for user-configurable stuff, or things that I want to be dynamically changed from time to time. This conversation was more about having a deplorable configuration that wouldn’t disrupt project updates. Sounds like your scenario does overlap - though in your case I’d put most of those things in .env and that would solve it.
At this point I’m pretty decided on shipping with the preconfigured local namespace and instructions on how to add to it. Once I write the class overrides to give it preference I will share them here.


RE: Best Practices: Sharing a project - littlej - 02-04-2020

OK, I'm sorry. Maybe my understanding was different. Translations issues :-) Tell me, or feel free to delete my messages for a cleaner conversation, no problem ;-)
Just to finish, ENV file is not a great solution. If I want to modify a token from the app frontend, i have to re-generate the env file (might be a security issue, and if something goes wrong with this, the whole app shuts down). So, config folder is not a good place (your topic), env file isn't great, and there is no way I will use a db for this :-) Conclusion... JSON seems to be my only friend and I am gonna have to keep this unused "Config" folder in my app :-)