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

Add use client directives to the created mjs wrappers #590

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Andarist
Copy link
Member

fixes bvaughn/react-error-boundary#182

I'm not 100% sure if this should be done at all though. It doesn't solve the case when the directive is in non-entrypoint file.

@Andarist Andarist requested a review from emmatown March 26, 2024 07:51
Copy link

changeset-bot bot commented Mar 26, 2024

⚠️ No Changeset found

Latest commit: 985e57f

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

exports.a = a;

⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ dist/pkg.cjs.mjs ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯
'use client';
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

now the use client directive is in this file and the one that it reexports (the CJS file) - I think it should be harmless, right?

Copy link

codecov bot commented Mar 26, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 92.39%. Comparing base (9f44a11) to head (985e57f).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #590   +/-   ##
=======================================
  Coverage   92.38%   92.39%           
=======================================
  Files          39       39           
  Lines        2049     2051    +2     
  Branches      625      639   +14     
=======================================
+ Hits         1893     1895    +2     
  Misses        146      146           
  Partials       10       10           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

"use client" not appearing in the ESM entry
1 participant