Skip to content

iyolee/mini-vue

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mini-vue

A mini Vue Framework.

run

npm install
npm run dev

Generating a file vue.js in the dist directory.

build

npm install
npm run build

Generating a file vue.min.js in the dist directory.

Usage

<div id="app">
  <p>{{person.name}}</p>
  <p v-text="msg"></p>
  <p>{{msg}}</p>
  <p v-html="msg"></p>
  <input type="text" v-model="msg">
  <button v-on:click="clickMe">按钮</button>
</div>
<script type="text/javascript" src="./dist/vue.min.js"></script>
<script>
  new Vue({
    el: '#app',
    data: {
      msg: 'hello vue',
      person: {
        name: 'leeper'
      }
    },
    methods: {
      clickMe() {
        this.msg = 'hello world',
        this.person.name = 'Jenkin Lee'
      }
    }
  })
</script>

LICENSE

MIT

About

A mini Vue Framework

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published