Skip to content

Commit

Permalink
fix: markdown-it types
Browse files Browse the repository at this point in the history
  • Loading branch information
0x-jerry committed Oct 6, 2024
1 parent d0615fb commit 27a4a6f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import { HexoCompletionProvider } from './hexoCompletionProvider';
import plugin from './markdownItHexoResource';
import { getConfig, ConfigProperties } from './configs';
import { registerTreeViews } from './treeViews';
import type { MarkdownIt } from './md-it';

export function activate(context: ExtensionContext) {
// Only activate when open with a workspace folder, close #98.
Expand Down
2 changes: 1 addition & 1 deletion src/markdownItHexoResource.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import path from 'path';
import { Uri, window } from 'vscode';
import { ConfigProperties, AssetFolderType, configs, getConfig } from './configs';
import { isVirtualWorkspace } from './utils';
import { Token, type StateInline } from './md-it';
import { Token, type MarkdownIt, type StateInline } from './md-it';

interface ResolveHexoTag {
(status: StateInline, ...attrs: string[]): any;
Expand Down
4 changes: 3 additions & 1 deletion src/md-it/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
import type MarkdownIt from 'markdown-it';

export { default as Token } from 'markdown-it/lib/token.mjs';

export type { StateInline } from 'markdown-it/index.js';

export type * as MarkdownIt from 'markdown-it';
export type { MarkdownIt };

0 comments on commit 27a4a6f

Please sign in to comment.