question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Hi! Thanks for the awesome package!

I was using this package just fine in another project, until recently when I started a new project with the following (relevant) dependencies:

"dependencies": {
   "esbuild": "^0.13.3",
    "mdx-bundler": "^6.0.1",
    "next": "^11.1.2",
  },

I’m seeing this eror:

Error: Build failed with 1 error:
_mdx_bundler_entry_point-e7c96812-becd-49d9-be41-95bf61d93768.mdx:0:0: error: [plugin: esbuild-xdm]

Could you guys help me understand what’s going on and how to solve it?

Thanks!

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:1
  • Comments:7

github_iconTop GitHub Comments

1reaction
gr-qftcommented, Oct 3, 2021

Hi @BraydenTW , awesome, thanks for sharing! I went over the code and were able to see that the error in my code is due to the codes

const { frontmatter, code } = await bundleMDX(source, {
    xdmOptions(options) {
      options.remarkPlugins = [...(options.remarkPlugins ?? []), [remarkSlug]];
      options.rehypePlugins = [
        ...(options.rehypePlugins ?? []),
        rehypeMetaAttribute,
      ];

      return options;
    },
  });

so I just tried to debug again and was able to find out that the errors were due to libraries such as unist-util-visit no longer accept require syntax (so now I have to do for example import { visit } from "unist-util-visit";). After fixing all the imports things are working now for me.

Thanks again, and cheers!

0reactions
gr-qftcommented, Oct 3, 2021

@BraydenTW 👍 !

Read more comments on GitHub >

github_iconTop Results From Across the Web

Project build errors and warnings (PRJxxxx) - Microsoft Learn
The Visual Studio compilers and build tools can report many kinds of errors and warnings. After an error or warning is found, the...
Read more >
Fix a build error
Fix a build error · Right-click anywhere in the Error List window. · Select Copy List. · Open Microsoft Excel or Word (or...
Read more >
BUILD Error Messages - IBM
BUILD Error Messages. The messages in the pop-up panel showing the command progress indicate error and warning situations. In most cases, it should...
Read more >
Oh dear! Build errors? - LoopDocs - GitHub Pages
This page contains build error help for people updating their Loop app as well as brand new Loop app builders. Review the "obvious"...
Read more >
Remove "There were build errors. Would you like to continue ...
FYI. In Visual Studio 2019 Update 16.5 or later you can go to Tools > Options > Projects and Solutions > Build and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found