Skip to content

Commit

Permalink
Allow for multi-line imports and exports (#24)
Browse files Browse the repository at this point in the history
  • Loading branch information
karlhorky authored Aug 15, 2024
1 parent 3cde2e3 commit 4f3a95c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/vite-plugin-remdx/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import ColorReplacements from './lib/ColorReplacements.tsx';
type Slide = [string, Record<string, unknown>];

const EXPORT_DEFAULT_REGEXP = /export\sdefault\s/g;
const MODULE_REGEXP = /\\`|`(?:\\`|[^`])*`|(^(?:import|export).*$)/gm;
const MODULE_REGEXP = /\\`|`(?:\\`|[^`])*`|(^(?:import|export)[^;]+;)/gm;

const compileMDX = async (
content: string,
Expand Down

0 comments on commit 4f3a95c

Please sign in to comment.