There are a number of ways to manage config values within your app. All of our API enpoints are via .NET as well. Our aurelia sites are usually the only consumer of the API so for us it makes sense to build out the Aurelia app within that same .NET sln. For us, what has worked out the best is to keep all the config values within our web.config (we haven’t moved over to .NET CORE yet) since many of them are needed for the API anyways. Then all configs are located in a single location which is way easier to maintain. The way I’ve made those configs consumable via aurelia was to just build out the index.cshml (our aurelia landing page) with the config object built right into the HTML as an object literal (injected via the .net Controller), which I called dotnetVars as a global object, which also includes the baseUrl which is also injected into the HTML attr. Then in aurelia i just ref that global object at run time in my own app-config.js class file so that I then have access to it as a singleton anywhere within my code that I need it.
1 Like