Skip to content

Commit 78a6852

Browse files
cursoragentovflowd
andcommitted
fix(vercel): restore mdx defaults for shiki
Assisted-by: Codex 5.3 Co-authored-by: Claudio Wunder <[email protected]>
1 parent 1a61747 commit 78a6852

2 files changed

Lines changed: 19 additions & 0 deletions

File tree

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
import assert from 'node:assert/strict';
2+
import { describe, it } from 'node:test';
3+
4+
describe('platform-vercel next.platform.config', () => {
5+
it('defines shiki mdx defaults for Vercel builds', async () => {
6+
const { default: platform } = await import('../next.platform.config.mjs');
7+
8+
assert.deepEqual(platform.mdx, {
9+
wasm: true,
10+
twoslash: true,
11+
});
12+
});
13+
});

packages/platform-vercel/next.platform.config.mjs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,4 +25,10 @@ export default {
2525
'@platform/analytics': '@node-core/platform-vercel/analytics',
2626
'@platform/instrumentation': '@node-core/platform-vercel/instrumentation',
2727
},
28+
mdx: {
29+
// Vercel supports the fast Oniguruma WASM engine and twoslash transforms,
30+
// so keep parity with the default standalone config.
31+
wasm: true,
32+
twoslash: true,
33+
},
2834
};

0 commit comments

Comments
 (0)