4 ms·
Version with debug enabled: <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script> Production version: <script src="https://cdn.jsdeli
by shakna 8y ago
Version with debug enabled:
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
Production version:
<script src="https://cdn.jsdelivr.net/npm/vue"></script>
If you need something more complex, vue-cli has webpack inbuilt:
vue init webpack my-project
cd my-project
npm install
npm run dev
Or if you need webpack, but not the complexity, swap the word 'webpack' in the above command to 'webpack-simple'.
... Vue has already done the hard work of getting the build apps configured for you.
- baby 8y agoVue also has a graphic interface now, try `vue ui`
- The_suffocated 8y agoI don't follow. How to use Vue's single-file component if you only load Vue from a script tag? And can I use Brunch instead of Webpack if I want to use single-file components?
- crazyideaman 8y agoVue's single file components (SFC) require a build tool such as Webpack or Browserify. See https://vuejs.org/v2/guide/single-file-components.html https://vuejs.org/v2/guide/single-file-components.html
- shakna 8y ago> And can I use Brunch instead of Webpack if I want to use single-file components? Probably, but Vue only officially supports Webpack or Browserify.