-
-
Notifications
You must be signed in to change notification settings - Fork 622
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
fix(types): useAtom with one type argument for primitive atoms #2386
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit f0cb490:
|
Size Change: 0 B Total Size: 70.8 kB ℹ️ View Unchanged
|
Preview in LiveCodesLatest commit: f0cb490
See documentations for usage instructions. |
@hatemhosny Unfortunately, it causes an error. Empty imports? |
It seems Jotai is not being bundled. The GitHub action will not bundle the files, it can just make them available as data urls. The import map was indeed loaded. You can view project json: app menu -> export -> export project (json) It looks like this: {
...
"imports": {
"jotai": "data:application/javascript;charset=UTF-8;base64,ZXhwb3J0ICogZnJvbSAnam90YWkvdmFuaWxsYSc7CmV4cG9ydCAqIGZyb20gJ2pvdGFpL3JlYWN0JzsK"
},
...
} The data url is loaded like that: export * from 'jotai/vanilla';
export * from 'jotai/react'; Which gives the error message. You can either:
If you want the import map to appear in UI (custom settings) put the {
...
"customSettings": {
"imports": {
"jotai": "..."
}
},
...
} |
@hatemhosny
No, I don't need that. |
Works now! 🎉 |
I wonder if the action works from forked repo, though. Will see. |
Very nice 🎉
I will do a test PR to demonstrate that from an account with no permissions on your repo. |
It works :) |
@hatemhosny |
This has been asked several times. Hope this doesn't break some usages.