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

fix: Improve macro error #2049

Merged
merged 1 commit into from
Oct 16, 2024
Merged

fix: Improve macro error #2049

merged 1 commit into from
Oct 16, 2024

Conversation

timofei-iatsenko
Copy link
Collaborator

Description

webpack (and nextjs) for some reason doesn't read message from error but instead rethrow the first frame of the stacktrace

So this fix will turn error from this

wait  - compiling /examples (client and server)...
error - ./src/pages/examples.tsx
TypeError: Cannot read properties of undefined (reading 'find')

to this:

image

Types of changes

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Examples update

Fixes # (issue)

Checklist

  • I have read the CONTRIBUTING and CODE_OF_CONDUCT docs
  • I have added tests that prove my fix is effective or that my feature works
  • I have added the necessary documentation (if appropriate)

@timofei-iatsenko timofei-iatsenko changed the base branch from main to next October 16, 2024 09:54
@timofei-iatsenko timofei-iatsenko changed the title Improve macro error fix: Improve macro error Oct 16, 2024
Copy link

vercel bot commented Oct 16, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
js-lingui ✅ Ready (Inspect) Visit Preview Oct 16, 2024 9:55am

Copy link

size-limit report 📦

Path Size
./packages/core/dist/index.mjs 2.88 KB (0%)
./packages/detect-locale/dist/index.mjs 723 B (0%)
./packages/react/dist/index.mjs 1.68 KB (0%)
./packages/remote-loader/dist/index.mjs 7.26 KB (0%)

@andrii-bodnar andrii-bodnar merged commit aaf079a into next Oct 16, 2024
11 of 12 checks passed
@andrii-bodnar andrii-bodnar deleted the improve-macro-error branch October 16, 2024 10:43
@andrii-bodnar andrii-bodnar added this to the v5 milestone Oct 23, 2024
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.

2 participants