8000 refactor(example): tidy up directory structure · vuejs/vue-class-component@3d1634b · GitHub
[go: up one dir, main page]

Skip to content

Commit 3d1634b

Browse files
committed
refactor(example): tidy up directory structure
1 parent 6ec2f5f commit 3d1634b

File tree

9 files changed

+8
-7
lines changed
  • 9 files changed

    +8
    -7
    lines changed

    example/example.html renamed to example/index.html

    Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -2,7 +2,7 @@
    22
    <html lang="en">
    33
    <head>
    44
    <meta charset="utf-8">
    5-
    <title></title>
    5+
    <title>Vue Class Component Example</title>
    66
    </head>
    77
    <body>
    88
    <div id="app"></div>

    example/App.vue renamed to example/src/App.vue

    Lines changed: 3 additions & 3 deletions
    Original file line numberDiff line numberDiff line change
    @@ -19,9 +19,9 @@
    1919

    2020
    <script lang="ts">
    2121
    import Vue from 'vue'
    22-
    import Component from '../lib/index'
    23-
    import Hello from './Hello.vue'
    24-
    import World from './World'
    22+
    import Component from '../../lib/index'
    23+
    import Hello from './components/Hello.vue'
    24+
    import World from './components/World'
    2525
    import { mapGetters, mapActions } from 'vuex'
    2626
    2727
    // We declare the props separately

    example/Hello.vue renamed to example/src/components/Hello.vue

    Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -4,7 +4,7 @@
    44

    55
    <script lang="ts">
    66
    import Vue from 'vue'
    7-
    import Component from '../lib/index'
    7+
    import Component from '../../../lib/index'
    88
    99
    @Component
    1010
    export default class Hello extends Vue {

    example/World.tsx renamed to example/src/components/World.tsx

    Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -1,5 +1,5 @@
    11
    import Vue, { CreateElement } from 'vue'
    2-
    import Component from '../lib/index'
    2+
    import Component from '../../../lib/index'
    33

    44
    @Component
    55
    export default class World extends Vue {
    File renamed without changes.
    File renamed without changes.
    File renamed without changes.
    File renamed without changes.

    example/webpack.config.js

    Lines changed: 2 additions & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -2,7 +2,8 @@ const VueLoaderPlugin = require('vue-loader/lib/plugin')
    22

    33
    module.exports = {
    44
    mode: 'development',
    5-
    entry: './example/example.ts',
    5+
    context: __dirname,
    6+
    entry: './src/main.ts',
    67
    output: {
    78
    path: __dirname,
    89
    filename: 'build.js'

    0 commit comments

    Comments
     (0)
    0