Notice: The Monaca & Onsen UI Community Forum is shutting down.

For Onsen UI bug reports, feature requests and questions, please use the Onsen UI GitHub issues page. For help with Monaca, please contact Monaca Support Team.

Thank you to all our community for your contributions to the forum. We look forward to hearing from you in the new communication channels.

(solved) Unable to load plugins (plugin.apply is not a function error)



  • Having some issues getting my environment setup. I’m using cordova as a base, with vue, onsen ui components, and the vue-onsen bindings. I can get it to run as ios and android, it works when I just use a single vue component, but when I add in vue-onsen and onsen ui it get thrown some errors. I’m using Browserify as well. Below is my main.js where I am thinking the problem may lie. Would love some help, and I’m pretty new to all of this. Thanks!

    UPDATE - Solved

    var Vue = require('vue');
    var VueOnsen = require('vue-onsenui');
    var ons = require('onsenui');
    var MainPage = require('./MainPage.vue');
    var SecondPage = require('./SecondPage.vue');
    var App = require('./App.vue');
    
    Vue.use(Onsenui);
    Vue.use(VueOnsen, {
      components: {
        MainPage,
        SecondPage
      }
    });
    
    ons.ready(() => {
      new Vue({
        el: 'body',
        components: { App }
      });
    });