Skip to content

Commit

Permalink
feat: complete transition to shiki-es
Browse files Browse the repository at this point in the history
  • Loading branch information
Akryum committed Dec 19, 2022
1 parent e389cb0 commit 7c2133d
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 6 deletions.
2 changes: 1 addition & 1 deletion packages/histoire/package.json
Expand Up @@ -66,7 +66,7 @@
"pathe": "^0.2.0",
"picocolors": "^1.0.0",
"sade": "^1.8.1",
"shiki": "0.11.1",
"shiki-es": "^0.1.2",
"sirv": "^2.0.2",
"tinypool": "^0.1.2",
"vite-node": "0.26.0"
Expand Down
4 changes: 2 additions & 2 deletions packages/histoire/src/node/markdown.ts
@@ -1,6 +1,6 @@
import MarkdownIt from 'markdown-it'
import matter from 'gray-matter'
import shiki from 'shiki'
import { getHighlighter } from 'shiki-es'
import anchor from 'markdown-it-anchor'
import attrs from 'markdown-it-attrs'
import emoji from 'markdown-it-emoji'
Expand Down Expand Up @@ -28,7 +28,7 @@ function notifyMarkdownListChange () {
}

export async function createMarkdownRenderer (ctx: Context) {
const highlighter = await shiki.getHighlighter({
const highlighter = await getHighlighter({
theme: 'github-dark',
})

Expand Down
2 changes: 1 addition & 1 deletion packages/histoire/src/node/vite.ts
Expand Up @@ -141,7 +141,7 @@ export async function getViteConfigWithPlugins (isServer: boolean, ctx: Context)
],
include: optimizeDeps([
'flexsearch',
'shiki',
'shiki-es',
// Shiki dependencies
'vscode-oniguruma',
'vscode-textmate',
Expand Down
7 changes: 5 additions & 2 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 7c2133d

Please sign in to comment.