1

I'd like to be able to determine programmatically whether the app was built in debug or release mode. I'd like to be able to write something like:

if(isDebug) {
    //do domething.
}
else {
    //do something else.
}
Mig82
  • 4,856
  • 4
  • 40
  • 63

1 Answers1

2

After using the Chrome debugger I was able to unearth the solution. There's a constant set during the build process which you can query in order to determine whether the app has been built in debug or release mode.

if(kony.constants.RUNMODE === "debug" || appConfig.isDebug) {
    //do domething.
}
else {
    //do something else.
}
Mig82
  • 4,856
  • 4
  • 40
  • 63