Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ReferenceError: navigator is not defined #312

Open
eunos-1128 opened this issue Sep 4, 2022 · 0 comments
Open

ReferenceError: navigator is not defined #312

eunos-1128 opened this issue Sep 4, 2022 · 0 comments

Comments

@eunos-1128
Copy link

eunos-1128 commented Sep 4, 2022

After ns preview I got this message and could not see the preview.

@halfnelson
Can you investigate this problem?

ReferenceError: navigator is not defined
    at standardBrowserEnv (file:///var/mobile/Containers/Data/Application/5145D892-1D78-4984-B2AB-6D78652D5C96/Library/preview/vendor.js:48608:41)
    at Object../node_modules/axios/lib/helpers/isURLSameOrigin.js (file:///var/mobile/Containers/Data/Application/5145D892-1D78-4984-B2AB-6D78652D5C96/Library/preview/vendor.js:48657:7)
    at webpack_require (file:///var/mobile/Containers/Data/Application/5145D892-1D78-4984-B2AB-6D78652D5C96/Library/preview/runtime.js:28:33)
    at fn (file:///var/mobile/Containers/Data/Application/5145D892-1D78-4984-B2AB-6D78652D5C96/Library/preview/runtime.js:231:21)
    at Object../node_modules/axios/lib/adapters/xhr.js (file:///var/mobile/Containers/Data/Application/5145D892-1D78-4984-B2AB-6D78652D5C96/Library/preview/vendor.js:47307:23)
    at webpack_require (file:///var/mobile/Containers/Data/Application/5145D892-1D78-4984-B2AB-6D78652D5C96/Library/preview/runtime.js:28:33)
    at fn (file:///var/mobile/Containers/Data/Application/5145D892-1D78-4984-B2AB-6D78652D5C96/Library/preview/runtime.js:231:21)
    at getDefaultAdapter (file:///var/mobile/Containers/Data/Application/5145D892-1D78-4984-B2AB-6D78652D5C96/Library/preview/vendor.js:48255:15)
    at Object../node_modules/axios/lib/defaults.js (file:///var/mobile/Containers/Data/Application/5145D892-1D78-4984-B2AB-6D78652D5C96/Library/preview/vendor.js:48286:12)
    at webpack_require (file:///var/mobile/Containers/Data/Application/5145D892-1D78-4984-B2AB-6D78652D5C96/Library/preview/runtime.js:28:33)

This is the package.json I use.

{
  "name": "myapp",
  "main": "app/app.ts",
  "version": "1.0.0",
  "private": true,
  "dependencies": {
    "@nativescript/core": "~8.3.0",
    "@nativescript/theme": "^3.0.2",
    "assert": "^2.0.0",
    "axios": "^0.21.4",
    "browserify-zlib": "^0.2.0",
    "buffer": "^6.0.3",
    "https-browserify": "^1.0.0",
    "moment": "^2.29.1",
    "nativescript-social-share": "^1.6.0",
    "net": "^1.0.2",
    "os-browserify": "^0.3.0",
    "punycode": "^2.1.1",
    "q": "^1.5.1",
    "qs": "^6.11.0",
    "spotify-web-api-js": "^1.5.1",
    "stream-browserify": "^3.0.0",
    "stream-http": "^3.2.0",
    "svelte-hmr": "^0.14.12",
    "svelte-native": "~1.0.0",
    "tty-browserify": "^0.0.1",
    "url": "^0.11.0"
  },
  "devDependencies": {
    "@nativescript/preview-cli": "1.0.1",
    "@nativescript/types": "~8.3.0",
    "@nativescript/webpack": "~5.0.6",
    "svelte": "~3.44.0",
    "svelte-loader": "^3.1.2",
    "svelte-native-preprocessor": "^1.0.0",
    "svelte-preprocess": "^4.7.0",
    "typescript": "~4.5.5"
  }
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant