-
Notifications
You must be signed in to change notification settings - Fork 222
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
Angular 6 Uncaught ReferenceError: process is not defined #691
Comments
Most environments (webpack, browserify) by default define `process` as a shim for it. However, some environements don't supply it, so we should always guard against it not being defined fixes #691 (should be tested in a real angular app first)
Hey @diegotham, I think I have a fix for this (#692), but to test it out correctly, I’d need to check in a real app, would it be possible for you to give a minimal reproduction in a GitHub repo please? Thanks! |
Same issue. |
Workaround: |
Yes, @0x6368656174, both that would work, as well as Note that you can also shim process as described in algolia/angular-instantsearch#90 (comment) in (window as any).process = {
env: { DEBUG: undefined },
}; |
I'm also getting the same issue |
Same here |
Did you read the workaround @ArsalRaza @trsh ? |
The working workaround for this issue for now is to add: (window as any).process = {
env: { DEBUG: undefined },
}; to your polyfill.ts file in you Angular app, locking this issue since the workaround is easy for now. Until we find the right solution. |
UPDATE FROM MAINTAINERS
The working workaround for this issue for now is to add:
/UPDATE FROM MAINTAINERS
to your polyfill.ts file in you Angular app
Do you want to request a feature or report a bug?
Bug
What is the current behavior?
Angular does not provide a shim for "process" anymore (angular/angular-cli#9827 (comment)).
Error:
If the current behavior is a bug, please provide all the steps to reproduce and a minimal
JSFiddle example or a repository on GitHub that we can
npm install
and
npm start
.Just using the library in an Angular 6 throws the error
What is the expected behavior?
To use algoliasearch library in an Angular 6 app
The text was updated successfully, but these errors were encountered: