-
Notifications
You must be signed in to change notification settings - Fork 0
/
astro.config.mjs
41 lines (34 loc) · 888 Bytes
/
astro.config.mjs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import { defineConfig, passthroughImageService } from "astro/config";
import partytown from "@astrojs/partytown";
export default defineConfig({
image: {
service: passthroughImageService(),
},
integrations: [
partytown({
config: {
forward: ["dataLayer.push"],
},
}),
],
});
// import { visit } from "unist-util-visit";
// function fixRelativeLinksFromObsidianToAstro(options) {
// function visitor(node) {
// if (node.url.startsWith("http") || node.url.startsWith("/images/")) {
// return;
// }
// if (!node.url.startsWith("/")) {
// node.url = "./" + node.url;
// }
// }
// function transform(tree) {
// visit(tree, "image", visitor);
// }
// return transform;
// }
// export default defineConfig({
// markdown: {
// remarkPlugins: [[fixRelativeLinksFromObsidianToAstro, {}]],
// }
// });