r/GraphicsProgramming • u/Hot_Technology8777 • 16d ago
Question Boilerplate code question
Is it good practice to manually memorize and type out boilerplate code in graphics applications? Or is it the norm to copy and paste a lot of stuff? And yes it is a given that I should understand how the boilerplate code works and what it contains. I'm programming in SDL3 in C on vscode.
7
Upvotes
View all comments
0
u/[deleted] 14d ago
I mean, if you're doing a thing a lot across different projects you might want to wrap the parts of SDL3 keep writing over and over (or just all of SDL3) in you own library. Generally wrapping external dependencies is also just a good practice in case they for some reason die and you need to use something else, then you only have to change your wrapper and not all your code you've ever written.