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(mdx-loader): loader error message should display stacktrace if no extra MDX details #9091

Merged
merged 1 commit into from
Jun 22, 2023

Conversation

slorber
Copy link
Collaborator

@slorber slorber commented Jun 22, 2023

Motivation

When MDX throws a regular JS error without extra useful attributes, the error message is not really helpful because the stacktrace is not included.

In these cases we want the stacktrace to be printed as well to troubleshoot the problem.

Note, for now this only works in the Webpack dev server:

CleanShot 2023-06-22 at 11 48 17@2x

The console (start+build) will print an unhelpful stacktrace:

CleanShot 2023-06-22 at 11 49 38@2x

This is very likely related to this issue: #9023

Test Plan

local only 😓

@facebook-github-bot facebook-github-bot added the CLA Signed Signed Facebook CLA label Jun 22, 2023
@slorber slorber added pr: bug fix This PR fixes a bug in a past release. and removed CLA Signed Signed Facebook CLA labels Jun 22, 2023
@netlify
Copy link

netlify bot commented Jun 22, 2023

[V2]

Name Link
🔨 Latest commit 621b4e3
🔍 Latest deploy log https://app.netlify.com/sites/docusaurus-2/deploys/649419abd9fe7700084155f7
😎 Deploy Preview https://deploy-preview-9091--docusaurus-2.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@github-actions
Copy link

⚡️ Lighthouse report for the deploy preview of this PR

URL Performance Accessibility Best Practices SEO PWA Report
/ 🟠 88 🟢 97 🟢 92 🟢 100 🟠 89 Report
/docs/installation 🟠 71 🟢 100 🟢 92 🟢 100 🟠 89 Report

@github-actions
Copy link

Size Change: 0 B

Total Size: 1.1 MB

ℹ️ View Unchanged
Filename Size
website/.docusaurus/globalData.json 117 kB
website/build/assets/css/styles.********.css 113 kB
website/build/assets/js/main.********.js 828 kB
website/build/index.html 41 kB

compressed-size-action

@facebook-github-bot facebook-github-bot added the CLA Signed Signed Facebook CLA label Jun 22, 2023
@slorber slorber merged commit 0b3d5cb into main Jun 22, 2023
@slorber slorber deleted the slorber/better-mdx-loader-error-details branch June 22, 2023 14:44
This was referenced Oct 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Signed Facebook CLA pr: bug fix This PR fixes a bug in a past release.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants