It's just bad form and you should not do it. These developers you see examples from seem to be used to developing web applications in MVC and the like, where the appsettings file is the central place to put the "settings" of an app.
The thing is. Azure functions have a very specific place to put these settings. Locally you can put it in local.settings.json. This file is only used on you local machine for debugging. It's ignored for git and not pushed to the cloud.
When deploying to a function app in the azure cloud, you can set these settings for the production environment through the azure portal for azure functions in the settings tab.
The limitation with doing it this way is that the azure function settings only supports name value pairs. No complex objects and such. A feature many developeres like from the appsettings way of doing things. However! To change this appsettings file you have to redeploy a function. If you use the settings stuff in the azure portal you don't have to do that and you can have slot specific settings and such. In my opinion (others may disagree) changing configuration should never require redeploying something.
for more reading:
https://learn.microsoft.com/en-us/azure/azure-functions/functions-how-to-use-azure-function-app-settings?tabs=portal