Skip to content
This repository has been archived by the owner on Feb 12, 2024. It is now read-only.

fix: remove use of instanceof for CID class #3847

Merged
merged 5 commits into from
Sep 2, 2021
Merged

Conversation

achingbrain
Copy link
Member

@achingbrain achingbrain commented Sep 2, 2021

When we use ipjs to publish esm modules as esm and cjs, consuming code
can end up loading classes from different locations based on whether
the consuming code is esm or cjs so instanceof becomes unreliable.

Remove its use with the CID class since we dual publish that one.

When we use ipjs to publish esm modules as esm and cjs, consuming code
can end up loading classes from different locations based on whether
the consuming code is esm or cjs so `instanceof` becomes unreliable.

Remove it's use with the CID class since we dual publish that one.
@achingbrain achingbrain merged commit ebbb12d into master Sep 2, 2021
@achingbrain achingbrain deleted the fix/cid-instanceof branch September 2, 2021 18:08
SgtPooki referenced this pull request in ipfs/js-kubo-rpc-client Aug 18, 2022
When we use ipjs to publish esm modules as esm and cjs, consuming code
can end up loading classes from different locations based on whether
the consuming code is esm or cjs so `instanceof` becomes unreliable.

Remove its use with the CID class since we dual publish that one.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant