Skip to content

How to install plugin in Vue3? #60

@ThomasBullock

Description

@ThomasBullock

Installing plugins has changed in v3.
Can vue-mq be used with vue v3?

const chat = createApp(App);
chat.use(store);
chat.use(router);
chat.use(VueMq, {
  breakpoints: {
    mobile: 375,
    tablet: 680,
    laptop: 1280,
    desktop: Infinity,
  },
  defaultBreakpoint: "mobile",
});

chat.mount("#app");

Results in vue-mq.es.js?660e:122 Uncaught TypeError: Vue is not a constructor at Object.install (vue-mq.es.js?660e:122) at Object.use (runtime-core.esm-bundler.js?5c40:3360)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions