How to configure nuxt.js globally?

I have a configuration file in js format, and I don"t want to read the configuration every time I have a request. (what if I configure it in cdn,? (not so good on the server Synchronize in the past)
if I am writing a service like golang/php/c, I will certainly load the configuration file into memory and update the memory information regularly.
I wonder if it can be implemented in nuxt.js? Now it can be achieved in nuxtServerInit, but obsessive-compulsive disorder is a little uncomfortable.

Mar.03,2021

set the environment variable, and then read

through process.env
Menu