Skip to content
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 the named export 'Encoder' & 'Decoder' #1271

Closed
1 task done
akbhatiya812 opened this issue May 13, 2024 · 1 comment · Fixed by #1272
Closed
1 task done

Can't import the named export 'Encoder' & 'Decoder' #1271

akbhatiya812 opened this issue May 13, 2024 · 1 comment · Fixed by #1272
Labels
bug confirmed acknowledged as an issue released

Comments

@akbhatiya812
Copy link

Please, check for existing issues to avoid duplicates.

  • No similar issues found.

What happened?

I am using peerjs in react 18.3.1 & Its giving below error on import Peer from "peerjs"; (I also tried import {Peer} from "peerjs";)
ERROR in ./node_modules/peerjs/dist/bundler.mjs 1901:28-42
Can't import the named export 'Encoder' (imported as '$gCcbY$Encoder') from default-exporting module (only default export is available)

ERROR in ./node_modules/peerjs/dist/bundler.mjs 1902:28-42
Can't import the named export 'Decoder' (imported as '$gCcbY$Decoder') from default-exporting module (only default export is available)

How can we reproduce the issue?

No response

What do you expected to happen?

I am getting error in import peerjs

Environment setup

  • OS: Ubuntu 20.04
  • Platform: node 21.0.0
  • Browser: Chrome 125.0.6422.41

Is this a regression?

No response

Anything else?

No response

@akbhatiya812 akbhatiya812 added bug unconfirmed not yet verified as an issue labels May 13, 2024
jonasgloning added a commit that referenced this issue May 14, 2024
Using CBOR forces us to choose between #1271 and #1247. Our complicated
importing and bundling situation makes using this library very hard.

CBOR support has been undocumented, and we are not aware of significant
usage in the wild. Therefore, we do not consider this a breaking change.
To make our expectations clearer, this PR also marks MessagePack as
`experimental`.

We will improve our importing and bundling situation before
reintroducing CBOR via a plugin.

Closes #1271
jonasgloning added a commit that referenced this issue May 14, 2024
Using CBOR forces us to choose between #1271 and #1247. Our complicated
importing and bundling situation makes using this library very hard.

CBOR support has been undocumented, and we are not aware of significant
usage in the wild. Therefore, we do not consider this a breaking change.
To make our expectations clearer, this PR also marks MessagePack as
`experimental`.

We will improve our importing and bundling situation before
reintroducing CBOR via a plugin.

Closes #1271
@jonasgloning jonasgloning added the confirmed acknowledged as an issue label May 14, 2024 — with Linear
@jonasgloning jonasgloning removed the unconfirmed not yet verified as an issue label May 14, 2024
github-actions bot pushed a commit that referenced this issue May 14, 2024
## [1.5.4](v1.5.3...v1.5.4) (2024-05-14)

### Bug Fixes

* **deps:** update dependency webrtc-adapter to v9 ([#1266](#1266)) ([5536abf](5536abf))
* remove CBOR ([badc9e8](badc9e8)), closes [#1271](#1271) [#1247](#1247) [#1271](#1271)
Copy link

🎉 This issue has been resolved in version 1.5.4 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug confirmed acknowledged as an issue released
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants