wmr icon indicating copy to clipboard operation
wmr copied to clipboard

@mdx-js/rollup plugin doesn't work in development mode

Open rschristian opened this issue 2 years ago • 0 comments

Discussed in https://github.com/preactjs/wmr/discussions/925

Originally posted by offsounder April 30, 2022 Hello,

I'm trying to use the @mdx-js/rollup plugin with wmr, however it errors out when running in development mode with the following message: Cannot read properties of undefined (reading '0').

When building with wmr --prerender, the md is correctly rendered to html.

Any ideas on what is going on?

map.sourcesContent might not exist so this throws:

https://github.com/preactjs/wmr/blob/1d304458829ebf18f219851eb4e55b313d1f7d65/packages/wmr/src/lib/sourcemap.js#L112

rschristian avatar May 01 '22 01:05 rschristian