You can subscribe to changes of system environment variables in the following ways:
Use the onConfigurationUpdate callback to subscribe to or listen to system environment variable changes (including the language, color mode, and screen orientation).
For details, see Obtaining/Setting Environment Variables.