Skip to content

Instantly share code, notes, and snippets.

@sparrow
Last active June 6, 2017 12:01

Revisions

  1. sparrow revised this gist Jun 6, 2017. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions vue-component.vue
    Original file line number Diff line number Diff line change
    @@ -5,8 +5,8 @@
    <p>
    Two-way bound value is {{ text }}
    </p>
    </div>
    <some-component></some-component>
    </div>
    <some-component></some-component>
    </div>
    </template>

  2. sparrow revised this gist Jun 6, 2017. No changes.
  3. sparrow revised this gist Jun 6, 2017. 1 changed file with 15 additions and 13 deletions.
    28 changes: 15 additions & 13 deletions vue-component.vue
    Original file line number Diff line number Diff line change
    @@ -1,26 +1,28 @@
    <template>
    <div class="root">
    <div>
    <input id="input" v-model="text" type="text" />
    <p>
    Two-way bound value is {{ text }}
    </p>
    </div>
    <some-component></some-component>
    </div>
    <div class="root">
    <div>
    <input id="input" v-model="text" type="text" />
    <p>
    Two-way bound value is {{ text }}
    </p>
    </div>
    <some-component></some-component>
    </div>
    </template>

    <script>
    import SomeComponent from './Cell.vue'
    export default {
    components: { SomeComponent },
    components: { SomeComponent },
    data () {
    return {
    text: 'New Vue App',
    }
    return {
    text: 'New Vue App',
    }
    }
    }
    </script>

    <style scoped>
    .root {
    background-color: #34495e;
  4. sparrow created this gist Jun 6, 2017.
    30 changes: 30 additions & 0 deletions vue-component.vue
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,30 @@
    <template>
    <div class="root">
    <div>
    <input id="input" v-model="text" type="text" />
    <p>
    Two-way bound value is {{ text }}
    </p>
    </div>
    <some-component></some-component>
    </div>
    </template>
    <script>
    import SomeComponent from './Cell.vue'
    export default {
    components: { SomeComponent },
    data () {
    return {
    text: 'New Vue App',
    }
    }
    }
    </script>
    <style scoped>
    .root {
    background-color: #34495e;
    color: #fff;
    width: 100%;
    }
    </style>