-
-
Notifications
You must be signed in to change notification settings - Fork 596
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
Can't import parse in svelte #1766
Comments
Thanks for opening this issue!
|
@vipersils Can you ensure the EventEmitter loaded? LiveQuerySubscription extends the EventEmitter Parse-SDK-JS/src/EventEmitter.js Lines 12 to 14 in 51c269f
|
Adding this to my code: yields:
The documentation on the above link also explicitly states that libraries should not rely on that and this should be reported as a bug to them:
I'm guessing it can be worked around by doing some polyfill magic with the vite configs though based on this. |
I can confirm that using https://www.npmjs.com/package/vite-plugin-node-polyfills works as a workaround. |
Completed by #2109 |
New Issue Checklist
Issue Description
Steps to reproduce
Now add this line e.g. to routes/Header.svelte:
import Parse from "parse/node";
And launch the site, check the JS console.
Actual Outcome
Expected Outcome
Parse gets imported correctly.
Environment
Package.json:
Server
no server involved, SDK version see above
linux
local
Database
none
none
none
Client
4.0.0-alpha.12
Logs
The text was updated successfully, but these errors were encountered: