-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Uncaught ReferenceError: global is not defined #12746
Comments
Hello, @FPRM 👋. Would you mind sharing your full |
@cwomack sure i tried what you mentionned in comment as i tried 'global': 'window' and 'global': {'window'} but none of 3 worked. Package.json
vite.config.js
|
@FPRM As your post, I saw your config is:
The
|
Hi @FPRM were you able to get this resolved, or do you still need assitance? |
@FPRM, it looks like there were steps missing from the Vue.js block switcher to ensure the polyfills needed to avoid these build errors are added into each project. I've created an issue on the We'll track the progress of the docs updates separately, and I'll close this issue out on the JS side since this should be resolved in v6 as well as have an easy workaround to implement the missing polyfills. Feel free to reply back if you disagree or have further questions on this. Thanks! |
Before opening, please confirm:
JavaScript Framework
Vue
Amplify APIs
Not applicable
Amplify Categories
Not applicable
Environment information
Describe the bug
After installing the npm package and writing my code to initiate auth connexion, app it not rendering and got error
Uncaught ReferenceError: global is not defined
at ../node_modules/buffer/index.js (amazon-cognito-identity-js.js?v=ef93d19d:215:35)
at __require2 (chunk-AUZ3RYOM.js?v=ef93d19d:18:50)
at amazon-cognito-identity-js.js?v=ef93d19d:2716:29
who send me back to line 215
Buffer5.TYPED_ARRAY_SUPPORT = global.TYPED_ARRAY_SUPPORT !== void 0 ? global.TYPED_ARRAY_SUPPORT : typedArraySupport();
Expected behavior
Gehing able to render app and launch authentication with password and username to get tokens
Reproduction steps
Code Snippet
Log output
aws-exports.js
No response
Manual configuration
No response
Additional configuration
No response
Mobile Device
No response
Mobile Operating System
No response
Mobile Browser
No response
Mobile Browser Version
No response
Additional information and screenshots
No response
The text was updated successfully, but these errors were encountered: