npm vue-loader 9.3.0

latest releases: 17.4.2, 17.4.1, 17.4.0...
7 years ago

Breaking Change

Note: breaking change in a minor release because the 9.x line is considered pre-releases until Vue 2.0 is officially out.

  • Named exports support has been reverted. The module export behavior is now the same with vue-loader 8.x: ES2015 default export will be normalized into module.exports. This means the following are equivalent:

    import App from './App.vue'
    
    const App = require('./App.vue') // no .default required

    The main reasoning behind this behavior though, is because named exports are rarely used in *.vue files (they can always be extracted into a separate *.js file instead), but the normalizing behavior can make async Vue components easier to write. Consider:

    // 8.x & ^9.3 behavior
    const Foo = resolve => require(['./Foo.vue'], resolve)

    vs. without normalizing:

    // 9.1 & 9.2 behavior
    const Foo = resolve => require(['./Foo.vue'], m => resolve(m.default))

    Sorry if this caused confusion if you are currently using 9.2 with async components.

Don't miss a new vue-loader release

NewReleases is sending notifications on new releases.