PHP8.1.21版本已发布
vue8.1.21版本已发布
jquery8.1.21版本已发布

通过纯Vue.js构建Bootstrap组件

高洛峰
高洛峰 原创
2017-03-22 13:30:39 2347浏览

通过纯vue.js构建bootstrap组件

没有jQuery, bootstrap.js, 或不需要任何第三方插件。

This repository contains a set of native Vue.js components based on Bootstrap's markup and CSS. As a 
result no dependency on jQuery or Bootstrap's JavaScript is required. The only required dependencies are:

Vue.js (required ^0.12, test with 0.12.10).

Bootstrap CSS (required 3.x.x, test with 3.3.5). VueStrap doesn't depend on a very precise version of 
Bootstrap. Just pull the latest.

CommonJS

$ npm install vue-strap
 
var alert = require('vue-strap/src/alert');
// or
var alert = require('vue-strap').alert;
 
new Vue({
 components: {
 'alert': alert
 }
})

ES6

$ npm install vue-strap
 
import alert from 'vue-strap/src/alert'
// or
import { alert } from 'vue-strap'
 
new Vue({
 components: {
 alert
 }``
})

AMD

$ bower install vue-strap
 
define(['vue-strap'], function(VueStrap) { var alert = VueStrap.alert; ... });

以上就是利用纯Vue.js构建Bootstrap组件的内容,更多相关内容请关注PHP中文网(www.php.cn)!

相关文章:

强大Vue.js组件详细说明

Vue.js环境搭建教程介绍

超全面的vue.js使用总结

声明:本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系admin@php.cn核实处理。