UNPKG

bootstrap-vue-loader

Version:

A Webpack plugin for automatic BootstrapVue components and directives importing, mainly for treeshaking

22 lines (16 loc) 797 B
// IMPORTANT: Do NOT use ES2015 features in this file (except for modules). // This module is a runtime utility for cleaner component module output and will // be included in the final webpack user bundle. // Forked directly from the vuetify-loader https://github.com/vuetifyjs/vuetify-loader/blob/master/lib/runtime/installComponents.js module.exports = function installComponents (component, components) { var options = typeof component.exports === 'function' ? component.exports.extendOptions : component.options if (typeof component.exports === 'function') { options.components = component.exports.options.components } options.components = options.components || {} for (var i in components) { options.components[i] = options.components[i] || components[i] } }