Skip to content

Commit e5088a2

Browse files
committed
Move imports to the end
1 parent f2c8e83 commit e5088a2

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

packages/mdx/src/mdx-plugin/plugin.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,6 @@ export function remarkCodeHike(
3333
}
3434
})
3535

36-
addConfig(tree, config)
37-
38-
if (config.autoImport && !hasCodeHikeImport) {
39-
addImportNode(tree)
40-
}
41-
4236
try {
4337
await transformPreviews(tree)
4438
await transformScrollycodings(tree, config)
@@ -52,6 +46,12 @@ export function remarkCodeHike(
5246
console.error("error running remarkCodeHike", e)
5347
throw e
5448
}
49+
50+
addConfig(tree, config)
51+
52+
if (config.autoImport && !hasCodeHikeImport) {
53+
addImportNode(tree)
54+
}
5555
}
5656
}
5757

0 commit comments

Comments
 (0)