From 7467b126b6d69f072842cbeb6325f8fb4d44253c Mon Sep 17 00:00:00 2001 From: meteorlxy Date: Thu, 11 Apr 2024 22:59:09 +0800 Subject: [PATCH] chore: remove the extra type import --- src/node/markdown/markdown.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/node/markdown/markdown.ts b/src/node/markdown/markdown.ts index 24df22d0..31e1750b 100644 --- a/src/node/markdown/markdown.ts +++ b/src/node/markdown/markdown.ts @@ -16,7 +16,6 @@ import { tocPlugin, type TocPluginOptions } from '@mdit-vue/plugin-toc' import { slugify } from '@mdit-vue/shared' import MarkdownIt from 'markdown-it' import type { Options } from 'markdown-it' -import type StateCore from 'markdown-it/lib/rules_core/state_core.mjs' import anchorPlugin from 'markdown-it-anchor' import attrsPlugin from 'markdown-it-attrs' // @ts-expect-error: types of markdown-it-emoji are not up-to-date @@ -240,7 +239,7 @@ export const createMarkdownRenderer = async ( slugify, permalink: anchorPlugin.permalink.linkInsideHeader({ symbol: '​', - renderAttrs: (slug, state: StateCore) => { + renderAttrs: (slug, state) => { // Find `heading_open` with the id identical to slug const idx = state.tokens.findIndex((token) => { const attrs = token.attrs