1.导入select2.min.js
2.导入select2.min.css
3.然后require
4.select class="js-example-basic-multiple" multiple="multiple"
option value="AL" xxx.info /option
option value="WY" xxx.com /option
/select
5.script
$(function() {
$(".js-example-basic-multiple").select2();
});
/script