10

Convention over Configuration

Our programs need to be configured. Some of these configurations are things such as connection strings to a database or a URL for a REST API we are calling. These might change depending on the different environments our code is running in (e.g. development, testing, or production). On top of this, we often have to configure our code to be able to run as we expect. The type of configuration we do is often dictated by some third-party library or framework we’re using. In growing solutions, this type of configuration tends to also grow, and since configuration is often done at a specific point during the startup of the program, it’s not uncommon to end up with large files acting as dumping grounds for this type ...

Get Metaprogramming in C# now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.