Skip to content
This repository was archived by the owner on Dec 5, 2022. It is now read-only.

--hmr flag results in window undefined error #116

Closed
davidovich opened this issue Nov 12, 2018 · 2 comments
Closed

--hmr flag results in window undefined error #116

davidovich opened this issue Nov 12, 2018 · 2 comments

Comments

@davidovich
Copy link
Contributor

Version

N/A

Reproduction link

http://example.com

Platform and OS info

MacOS, ios, NativeScript 5.0

Steps to reproduce

install a new project with the vue-cli-template.
run a session with --hmr activated:

tns ios run --hmr #crashes (vue-hot-reload-api is currently at 2.3.0)

but:

npm install vue-hot-reload-api@2.3.1
tns ios run --hmr

No crash

What is expected?

The app is able to load

What is actually happening?

The app crashes on an unavailable window access:
JS ERROR ReferenceError: Can't find variable: window


vue-loader is pinned add 15.2.6 which has a sub-dependency of vue-hot-reload-api at 2.3.0, which has a bug accessing window even if not available. This is fixed in 2.3.1, so a bump of vue-loader to latest (15.4.2) would fix this sub-dependency.

NOTE: This form (issue-helper) is overly strict on reproduction links, as I don't have any, so I have to fill a random link. Also, how do I find the version of the vue-cli-template ?

@rigor789
Copy link
Member

Closing as outdated. HMR should be working in latest release (although it's still not perfect)

@nativescript-vue-bot
Copy link
Collaborator

We are locking this issue because it has been closed for more than 14 days.

If the issue comes up again please open a new issue with additional details.

@nativescript-vue nativescript-vue locked as resolved and limited conversation to collaborators Sep 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

No branches or pull requests

3 participants