wiki.techinc.nl/resources/src/vue/composition-api.js
Roan Kattouw 10fae048df Add Vue composition API plugin
Feature code that needs the composition API will need this as long as
we're still on Vue 2. This will also help migrate to Vue 3 more
seamlessly, as working around some breaking changes in Vue 3 requires
using the composition API.

Bug: T251974
Change-Id: I8e334ae5f447a8f9b64a7c910b2c1776cef118db
2021-11-03 23:15:57 +00:00

12 lines
419 B
JavaScript

/* global VueCompositionAPI */
// eslint-disable-next-line no-implicit-globals
var Vue = require( 'vue' );
// vue-composition-api.js requires the window.Vue global
window.Vue = Vue;
// Unfortunately, vue-composition-api.js creates a VueCompositionAPI global rather than exporting it
require( '../../lib/vue-composition-api/vue-composition-api.js' );
Vue.use( VueCompositionAPI );
module.exports = VueCompositionAPI;