2

I'm currently implementing a web application with the OpenUI5 framework. I'm also using the UI5 Tooling.

However, I could not find any documentation about how I can use environment variables inside my app. Normaly, in any Node.js application, I would use dotenv, but since process is not defined in an OpenUI5 application, it's not possible for me to do so.

So, my question is this: how can I define and then use environment variables in my OpenUI5 application? If code examples could also be provided, I would be very grateful.

Thank you!

mathlizee
  • 185
  • 2
  • 12
  • OpenUI5 is not a server side application though, the tooling is only used for the building of the app. The end result is a `Component-preload` file and some other bits and pieces which is front end only. What kind of environment variables were you thinking of? – Jorg Oct 21 '20 at 04:05
  • 1
    @Jorg 2 I need to access an authentication service, which URL and credentials changes whether I'm in a development or production environment. Furthermore, I don't want those credentials to be in my source code, since they would be publicly available and that would cause security issues. – mathlizee Oct 21 '20 at 23:32

0 Answers0