Skip to content

Commit fd2d846

Browse files
feat: increase Shiki from 1.4.0 to 3.4.0 (#160)
* Bump shiki version to 3.4.0 * Increase shiki rehype to 3.4.0 for plugin-code. This requires changing moduleResolution to Bundler (or newer) * update pnpm-lock.yaml * update docs to shiki 3.4.0
1 parent 0aa07c3 commit fd2d846

File tree

6 files changed

+140
-29
lines changed

6 files changed

+140
-29
lines changed

docs/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
"cpx": "^1.5.0",
2828
"jsom": "^1.0.0",
2929
"sass": "^1.69.5",
30-
"shiki": "^1.4.0",
30+
"shiki": "^3.4.0",
3131
"svelte": "catalog:",
3232
"svelte-check": "catalog:",
3333
"tailwindcss": "^3.3.5",

packages/carta-md/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
"remark-gfm": "^4.0.0",
4747
"remark-parse": "^11.0.0",
4848
"remark-rehype": "^11.1.0",
49-
"shiki": "^1.4.0",
49+
"shiki": "^3.4.0",
5050
"unified": "^11.0.5"
5151
},
5252
"keywords": [

packages/carta-md/src/lib/internal/highlight.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@ async function getManager() {
236236
// to prevent multiple calls to getManager from creating multiple instances
237237
// since shiki.getHighlighter is an async function.
238238
manager = (async () => ({
239-
shikiHighlighter: await shiki.getHighlighter({
239+
shikiHighlighter: await shiki.createHighlighter({
240240
langs: [],
241241
themes: []
242242
}),

packages/plugin-code/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
"build": "tsc && tscp"
1717
},
1818
"devDependencies": {
19-
"@shikijs/rehype": "^1.4.0",
19+
"@shikijs/rehype": "^3.4.0",
2020
"@types/node": "^18.16.3",
2121
"carta-md": "workspace:*",
2222
"typescript": "catalog:",
@@ -30,7 +30,7 @@
3030
],
3131
"version": "4.0.0",
3232
"dependencies": {
33-
"@shikijs/rehype": "^1.4.0",
33+
"@shikijs/rehype": "^3.4.0",
3434
"unified": "^11.0.5"
3535
},
3636
"keywords": [

pnpm-lock.yaml

Lines changed: 134 additions & 23 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"checkJs": false,
77
"esModuleInterop": true,
88
"forceConsistentCasingInFileNames": true,
9-
"moduleResolution": "node",
9+
"moduleResolution": "Bundler",
1010
"resolveJsonModule": false,
1111
"skipLibCheck": true,
1212
"sourceMap": true,

0 commit comments

Comments
 (0)