Closed
Description
Vue.js version
1.0.26
Steps to reproduce
vue -V
2.1.0
vue init webpack my-project
# press many times ENTER
cd my-project
npm i
# fill components like this https://gist.github.com/vird/e07fbff0cb56dcec5ec4ce2e2d125661
npm run dev
# open localhost:8080
# click focus text. See that textarea focused properly
# go to shared.js, replace 'focus' to 'focus '
# hotreload applied
# click focus text. shared.js?c91c:8 Uncaught TypeError: Cannot read property 'focus' of null
What is Expected?
textarea focused properly
What is actually happening?
shared.js?c91c:8 Uncaught TypeError: Cannot read property 'focus' of null
What happens
new instance of SharedController, new instance of Hello are created.
Nested has old SharedController that has reference to old Hello instance in textarea_get closure.
Expected Nested has new SharedController instance after hot reload
Sorry for posting here. But https://github.com/vuejs/vue-hot-reload-api/ has no issues tab.
Metadata
Metadata
Assignees
Labels
No labels