"npm run samples" leads to: "ReferenceError: Can't find variable: process"
See original GitHub issueVersion
2.2.0
Reproduction link
https://github.com/nativescript-vue/nativescript-vue
Platform and OS info
iOS 12.1 simulator / NativeScript 4.2.0 / macOS 10.14.3
Steps to reproduce
Follow CONTRIBUTING.md
:
# After cloning the repo
npm install
# In a background shell
npm run dev
npm run samples
# Select sample 127.js, and specify iOS
What is expected?
Sample 127 should launch without problem.
What is actually happening?
App bundle is able to be synced to simulator, but is unable to launch without crashing. See stack trace:
iOS: ***** Fatal JavaScript exception - application has been terminated. *****
iOS: Native stack trace:
iOS: 1 0x10e751c1f NativeScript::reportFatalErrorBeforeShutdown(JSC::ExecState*, JSC::Exception*, bool, bool)
iOS: 2 0x10e786caf -[TNSRuntime executeModule:referredBy:]
iOS: 3 0x10e1a61e3 main
iOS: 4 0x11229a575 start
iOS: 5 0x2
iOS: JavaScript stack trace:
iOS: 1 anonymous@file:///app/nativescript-vue.js:11267:20
2 evaluate@[native code]
3 moduleEvaluation@[native code]
4 @[native code]
5 promiseReactionJob@[native code]
6 require@[native code]
7 anonymous@file:///app/127.js:1:90
8 evaluate@[native code]
9 moduleEvaluation@[native code]
10 @[native code]
11 promiseReactionJob@[native code]
iOS: JavaScript error:
file:///app/nativescript-vue.js:11267:20: JS ERROR ReferenceError: Can't find variable: process
iOS: (CoreFoundation) *** Terminating app due to uncaught exception 'NativeScript encountered a fatal error: ReferenceError: Can't find variable: process
at
1 anonymous@file:///app/nativescript-vue.js:11267:20
2 evaluate@[native code]
3 moduleEvaluation@[native code]
4 @[native code]
5 promiseReactionJob@[native code]
6 require@[native code]
7 anonymous@file:///app/127.js:1:90
8 evaluate@[native code]
9 moduleEvaluation@[native code]
10 @[native code]
11 promiseReactionJob@[native code]
', reason: '(null)'
*** First throw call stack:
(
0 CoreFoundation 0x0000000111cd01bb __exceptionPreprocess 331
1 libobjc.A.dylib 0x0000000110ae0735 objc_exception_throw 48
2 NativeScript 0x000000010e7523aa _ZN12NativeScript30reportFatalErrorBeforeShutdownEPN3JSC9ExecStateEPNS0_9ExceptionEbb 2314
3 NativeScript 0x000000010e786caf -[TNSRuntime executeModule:referredBy:] 767
4 samples <…>
Other
I believe that process
is being referred to in nativescript-vue.js
.
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
dealing with the error 'ReferenceError: Can't find variable
I am using Nodejs. I am trying to import multiple functions and here is how I am doing it. I would love any...
Read more >How to Bundle JavaScript With Rollup — Step-by-Step Tutorial
This week, we're going to build our first project using Rollup, which is a build tool for bundling JavaScript (and stylesheets, but we'll...
Read more >@electron/remote - npm
@electron/remote is an Electron module that bridges JavaScript objects from the main process to the renderer process. This lets you access main- ...
Read more >Troubleshooting Common Errors - Gatsby
You may encounter an error like Error: ReferenceError: window is not defined that you didn't see in development if you reference browser globals...
Read more >ReferenceError: “process is not defined” - GIMTEC
This error is common in many frontend projects. You might have encountered it a few times, and it might come from a line...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
We’ve done some refactoring on our samples -
npm run samples
seems to be working for both ios and android. Let me know if you can try again and if the issue still happens for you!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.