-
-
Notifications
You must be signed in to change notification settings - Fork 5k
Closed
Description
Vue.js / vue-router versions
2.1.2 / 2.3.0
Reproduction Link
Steps to reproduce
Using Typescript 2.2.1 and Webpack 2.2.1
In VueRouter 2.2.1 importing was done with import VueRouter = require('vue-router') but it looks like in 2.3.0 it needs to be import VueRouter from 'vue-router'.
The issue is that it looks like the type definitions still define the export as export = VueRouter where it needs to be export default VueRouter now.
What is Expected?
Importing 'vue-router' the proper way should not give a compiler warning.
What is actually happening?
When Using: import VueRouter = require('vue-router')
You Get: Uncaught TypeError: VueRouter is not a constructor
When Using: import VueRouter from 'vue-router
You Get: Compiler warning that vue-router has no default export
lukepolo, mizdra, Allenice, eheikes, aramirez92 and 1 more
Metadata
Metadata
Assignees
Labels
No labels