A Vue.js 2.0 library project
Generated using vue-cli-template-library.
npm install mkplace-vue
mkplace-vue can be used as a module in both CommonJS and ES modular environments.
When in non-modular environment, mkplace-vue will register all the components to vue by itself.
//
// You can register a component manually
//
import { HelloWorld } from 'mkplace-vue';
export default {
...
components: {
HelloWorld
},
...
};
//
// or register the whole module with vue
//
import ModuleLibrary from 'mkplace-vue';
// Install this library
Vue.use(ModuleLibrary);
//
// You can register a component manually
//
var Vue = require('vue');
var ModuleLibrary = require('mkplace-vue');
var YourComponent = Vue.extend({
...
components: {
'hello-world': ModuleLibrary.HelloWorld
},
...
});
//
// or register the whole module with vue
//
var Vue = require('vue');
var ModuleLibrary = require('mkplace-vue');
// Install this library
Vue.use(ModuleLibrary);
<script src="path/to/vue/vue.min.js"></script>
<script src="path/to/mkplace-vue/dist/mkplace-vue.min.js"></script>
<!-- Components are registered globally -->
<hello-world></hello-world>
See the GitHub release history.
See CONTRIBUTING.md.