Checking Debug vs. Release

2 posts, 0 answers
  1. jmillar
    jmillar avatar
    33 posts
    Member since:
    Oct 2006

    Posted 27 Nov 2015 Link to this post

    Hi all;

    Can someone tell me a quick way to determine if my code is running in debug or release mode?  What I'm really trying to do is use one set of data connectors in dev, and another in production.

    Thanks,

    Jason

  2. Tina Stancheva
    Admin
    Tina Stancheva avatar
    3298 posts

    Posted 02 Dec 2015 Link to this post

    Hi Jason,

    In order to implement your logic in Telerik Platform you can use configuration-specific files. When you run a build, AppBuilder takes the file that matches the currently set build configuration and includes it in your application package. For example, when you run a build with the Debug configuration, AppBuilder takes index.debug.html and includes it in your application package as index.html.

    You can find more information on the configuration-specific files implementation here. In your case you can create a [dataConnectors].debug.js file using your data connectors for the dev environment and [dataConnectors].release.js for the production environment.

    Give this a try and let me know if it helps.

    Regards,
    Tina Stancheva
    Telerik
     

    Visit the Telerik Verified Plugins Marketplace and get the custom Cordova plugin you need, already tweaked to work seamlessly with AppBuilder.

     
Back to Top