Exclude widgets from mobile deployment

Hi, I wanted to use the AudioVideoPlayback widget on a desktop page. This works fine, but then the app no longer works in the Mendix Developer app. I even tried fixing components.json for it but I could not make it work. But I don't need it in the mobile part of the app. Is there any way to exclude widgets from mobile packaging?
1 answers

For now there is only a workaround which we have used in 5.13.1 to only include widgets for the mobile pages (create manually a widgetsmobile.js and copy/paste the individual widget you use in your mobile pages from the generated widgets.js in you deployment directory/widgets).

Make a copy of of the mxui.js (Modeler directory; C/prog.files/mendix/modeler...) and place this in the theme/js dir for example. Search for the line of code _131f.push("widgets/widgets.js"); and replace this with the following:

 if(typeof cordova !== 'undefined')

Note that this is really a hack for 5.13.1 specific. Don't know if next versions of the modeler will support this. Remember also that the order is important in your components.json (it's ignoring the index.html order of including your files).

We will post a new blog soon about our experiences with mobile/phonegap + Mendix on our website www.appronto.nl/blog