Hi, just upgraded my nextjs project to the latest versions yarn upgrade --latest and got this error:
./utils/parseMarkdown.js
Module parse failed: Optional chaining cannot appear in left-hand side (23:74)
File was processed with these loaders:
* ./node_modules/next/dist/build/webpack/loaders/next-swc-loader.js
You may need an additional loader to handle the result of these loaders.
| const source = section.answer;
| const mdxSource = await serialize(source);
> if (parsedPage.faq.data?.attributes.sections?.length > 0) parsedPage.faq.data?.attributes.sections[index].answer = mdxSource;
| }
| }
I am not sure, which package caused the error.
I assume the error came from next-mdx-remote, but it seems to be a problem with the loader.
If its not, I will create another ticket their.
Hi, just upgraded my nextjs project to the latest versions
yarn upgrade --latest
and got this error:I am not sure, which package caused the error. I assume the error came from next-mdx-remote, but it seems to be a problem with the loader. If its not, I will create another ticket their.
package.json