This repository contains a series of WordPress snippets that I have been compiling throughout my career as a professional.
In it you can find from a wp-config.php file with all the necessary functions for your website, even pieces of code to create your own 'post type' or add new options to the customizer.
Feel free to consult it and use the code you want.