79400989

Date: 2025-01-30 19:14:57
Score: 1
Natty:
Report link

Short answer, it depends on the tech. Node projects, for instance, have to be configured by JSON, but from there are different config flavors depending on your project architecture. Next.js servers will require additional configurations with their own set of rules. Typescript requires an additional configuration. So do the testing libraries and linters. Using Babel? Gonna need more config!

On top of this, there are different package managers that can be run on top of Node including NPM, Yarn, and PNPM, each with its own configuration preference. To confuse things more, there are certain architectures and libraries that will accept different types of configuration files, and might support, say, both YAML and JSON config files.

How to keep from being confused? Well, if your config files are missing your application won't work. It will at least throw an error and at worst refuse to run. The "decision" to be made will mostly be based on what the application supports and what you're most comfortable with. If I have a choice between YAML and JSON, I can appreciate that YAML might provide additional flexibility, but I'm more comfortable with JSON so I'll choose it every time. If I hit a roadblock where there's something I just CAN'T do using JSON...well I guess it's time to learn some YAML!

tl;dr: It depends! Basically it's project dependent.

Reasons:
  • Long answer (-1):
  • No code block (0.5):
  • Contains question mark (0.5):
  • Low reputation (1):
Posted by: Davey Sway