Ready to take your JavaScript development to the next level? Meet npm Enterprise - the ultimate in enterprise JavaScript. Learn more »

vue-template-merge-load

1.0.9 • Public • Published

Vue-template-merge-load

vue template static insert the HTML file . template combination .

Installing

    npm install vue-template-merge-load --save-dev

Example

carousel.vue ( Share a model object )

    <!-- only static path -->
    <div require="@/demo1.html"></div>
    <div require="@/demo2.html"></div>
    <div require="src/views/demo3.html"></div>

webpack.base.conf.js ( After add to vue-loader )

    { test: /\.vue$/,loader: 'vue-loader'..} ,
    {
        test: /carousel\.vue$/, // RegExp or Function
        loader: 'vue-template-merge-load',
        options:{ // Optional
            attr: 'require', // default
            alias: {
                '@': resolve('src/views')
                }
        }
    }

It might be used

function resolve(dir) { return path.join(__dirname, '..', dir) }

License

MIT

install

npm i vue-template-merge-load

Downloadsweekly downloads

3

version

1.0.9

license

MIT

last publish

collaborators

  • avatar
Report a vulnerability