Calaf
Calaf

Reputation: 10847

Storage needed for exploratory Vue.js examples

Just confirming a basic fact.

To run an introductory example

// Define a new component called button-counter
Vue.component('button-counter', {
  data: function () {
    return {
      count: 0
    }
  },
  template: '<button v-on:click="count++">You clicked me {{ count }} times.</button>'
})

the storage needed on my hard disk is of the order of 175MB.

Am I missing something, or is this the way it is with Vue.js v2?

Upvotes: 0

Views: 37

Answers (1)

yuriy636
yuriy636

Reputation: 11681

I'm guessing with 175MB you mean a CLI and NPM based development environment.

Well, no, in order to run that introductory example you don't necessarily need such environment.

You can follow the <script>-based development environment, which will take little to none space, because Vue will be loaded from a CDN.

That said, you could hit the limitations soon after "deepening", like when starting with Single File Components. Also the big part of QA and tutorials assume CLI env.


Keep in mind that this is the workflow with any modern JavaScript framework's dev environment. That taken space is there for a reason, and it is to help you build your app, for example with Vue's CLI you get "hot-reload, lint-on-save, and production-ready builds" and more. Also you can add NPM packages and import them into your project

Upvotes: 1

Related Questions