diff --git a/package-lock.json b/package-lock.json index 597651d..60ebd92 100644 --- a/package-lock.json +++ b/package-lock.json @@ -15,6 +15,7 @@ "devDependencies": { "@iconify-json/material-symbols": "^1.2.1", "@iconify-json/mdi": "^1.2.0", + "@mavrin/remark-typograf": "^2.2.0", "@sveltejs/enhanced-img": "^0.3.8", "@sveltejs/kit": "^2.0.0", "@sveltejs/vite-plugin-svelte": "^3.0.0", @@ -1073,6 +1074,17 @@ "@jridgewell/sourcemap-codec": "^1.4.14" } }, + "node_modules/@mavrin/remark-typograf": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@mavrin/remark-typograf/-/remark-typograf-2.2.0.tgz", + "integrity": "sha512-YzIIzPCIbycuzQn75zVslpK1uUC60qVxG+NlmtWMB1G2hsRGJu6JZhlldo32e8DiaAALr+dnndXLWv0sH1tSCw==", + "dev": true, + "dependencies": { + "lodash.escaperegexp": "^4.1.2", + "typograf": "^6.11.3", + "unist-util-visit": "^2.0.3" + } + }, "node_modules/@nodelib/fs.scandir": { "version": "2.1.5", "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", @@ -3178,6 +3190,12 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/lodash.escaperegexp": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/lodash.escaperegexp/-/lodash.escaperegexp-4.1.2.tgz", + "integrity": "sha512-TM9YBvyC84ZxE3rgfefxUWiQKLilstD6k7PTGt6wfbtXF8ixIJLOL3VYyV/z+ZiPLsVxAsKAFVwWlWeb2Y8Yyw==", + "dev": true + }, "node_modules/lodash.merge": { "version": "4.6.2", "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", @@ -4578,12 +4596,31 @@ } } }, + "node_modules/typograf": { + "version": "6.15.1", + "resolved": "https://registry.npmjs.org/typograf/-/typograf-6.15.1.tgz", + "integrity": "sha512-G1IIJlh4ycW+rvTspdgZKQoj/fKpmwif6MUhrmn3LY50W8njRnBqdFIJcfDqbmDg+RmmP51R9jdjjMwBYA5P0Q==", + "dev": true, + "engines": { + "node": ">= 4" + } + }, "node_modules/ufo": { "version": "1.5.4", "resolved": "https://registry.npmjs.org/ufo/-/ufo-1.5.4.tgz", "integrity": "sha512-UsUk3byDzKd04EyoZ7U4DOlxQaD14JUKQl6/P7wiX4FNvUfm3XL246n9W5AmqwW5RSFJ27NAuM0iLscAOYUiGQ==", "dev": true }, + "node_modules/unist-util-is": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/unist-util-is/-/unist-util-is-4.1.0.tgz", + "integrity": "sha512-ZOQSsnce92GrxSqlnEEseX0gi7GH9zTJZ0p9dtu87WRb/37mMPO2Ilx1s/t9vBHrFhbgweUwb+t7cIn5dxPhZg==", + "dev": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, "node_modules/unist-util-stringify-position": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/unist-util-stringify-position/-/unist-util-stringify-position-2.0.3.tgz", @@ -4597,6 +4634,35 @@ "url": "https://opencollective.com/unified" } }, + "node_modules/unist-util-visit": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/unist-util-visit/-/unist-util-visit-2.0.3.tgz", + "integrity": "sha512-iJ4/RczbJMkD0712mGktuGpm/U4By4FfDonL7N/9tATGIF4imikjOuagyMY53tnZq3NP6BcmlrHhEKAfGWjh7Q==", + "dev": true, + "dependencies": { + "@types/unist": "^2.0.0", + "unist-util-is": "^4.0.0", + "unist-util-visit-parents": "^3.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/unist-util-visit-parents": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-3.1.1.tgz", + "integrity": "sha512-1KROIZWo6bcMrZEwiH2UrXDyalAa0uqzWCxCJj6lPOvTve2WkfgCytoDTPaMnodXh1WrXOq0haVYHj99ynJlsg==", + "dev": true, + "dependencies": { + "@types/unist": "^2.0.0", + "unist-util-is": "^4.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, "node_modules/unplugin": { "version": "1.14.1", "resolved": "https://registry.npmjs.org/unplugin/-/unplugin-1.14.1.tgz", diff --git a/package.json b/package.json index c0209df..02b35a9 100644 --- a/package.json +++ b/package.json @@ -13,6 +13,7 @@ "devDependencies": { "@iconify-json/material-symbols": "^1.2.1", "@iconify-json/mdi": "^1.2.0", + "@mavrin/remark-typograf": "^2.2.0", "@sveltejs/enhanced-img": "^0.3.8", "@sveltejs/kit": "^2.0.0", "@sveltejs/vite-plugin-svelte": "^3.0.0", diff --git a/svelte.config.js b/svelte.config.js index f42bf70..7c94d89 100644 --- a/svelte.config.js +++ b/svelte.config.js @@ -1,13 +1,16 @@ import adapter from '@sveltejs/adapter-node'; import { vitePreprocess } from '@sveltejs/vite-plugin-svelte'; import {mdsvex} from "mdsvex"; +import remarkTypograf from "@mavrin/remark-typograf" /** @type {import('@sveltejs/kit').Config} */ const config = { extensions: ['.svelte', '.svx'], preprocess: [ vitePreprocess(), - mdsvex(), + mdsvex({ + remarkPlugins: [remarkTypograf] + }), ], kit: { adapter: adapter()