No description
  • Svelte 39.4%
  • JavaScript 28.3%
  • CSS 14.2%
  • TypeScript 13.8%
  • HTML 4.3%
Find a file
Daniel Kasmeroglu 2cfaa31c41
All checks were successful
Building remark-example Project / build (push) Successful in 28s
~ first attempt of a forgejo action
2026-05-06 11:51:02 +02:00
.forgejo/workflows ~ first attempt of a forgejo action 2026-05-06 11:51:02 +02:00
src ~ first attempt of a forgejo action 2026-05-06 11:51:02 +02:00
static + initial commit 2024-03-06 14:57:34 +01:00
.editorconfig + initial commit 2024-03-06 14:57:34 +01:00
.eslintignore + initial commit 2024-03-06 14:57:34 +01:00
.eslintrc.cjs + initial commit 2024-03-06 14:57:34 +01:00
.gitignore + initial commit 2024-03-06 14:57:34 +01:00
.npmrc + initial commit 2024-03-06 14:57:34 +01:00
.prettierignore + initial commit 2024-03-06 14:57:34 +01:00
.prettierrc + initial commit 2024-03-06 14:57:34 +01:00
Jenkinsfile ~ some adoptions as the build processes are now residing on a Jenkins agent 2026-01-12 18:51:21 +01:00
LICENSE + initial commit 2024-03-06 14:57:34 +01:00
mdsvex.config.js + added usage for remark-autolinker as well 2024-03-26 16:24:28 +01:00
package.json ~ chore: update dependencies 2026-04-28 16:54:09 +02:00
pnpm-lock.yaml ~ chore: update dependencies 2026-04-28 16:54:09 +02:00
README.md ~ fix: updated old github urls 2026-04-28 16:56:23 +02:00
svelte.config.js Revert "~ disable 'strict' build in order to render the page" 2024-03-23 18:37:46 +01:00
tsconfig.json ~ chore: updated dependencies 2024-08-23 19:51:17 +02:00
vite.config.ts + initial commit 2024-03-06 14:57:34 +01:00

StandWithUkraine

Readme

This is a simple show case for the use of remark-imagetools, remark-svelte-auto-import and remark-autolinker

Demo

Netlify Status

Example deployment: Demo

Usage

In order to run this example, use the following commands:

pnpm install
pnpm dev

You can see the examples in your browser:

NOTE: The port number might differ if it's already occupied.

Configuration

vite.config.ts

Add the plugin imagetools to this configuration as it provides the image processing functionality itself:

export default defineConfig({
    plugins: [
        imagetools(),
        sveltekit()
    ]
});

svelte.config.js

Add support for mdsvex to svelte:

import mdsvexConfig from './mdsvex.config.js'

const config = {

    ...

    // Consult https://kit.svelte.dev/docs/integrations#preprocessors
    // for more information about preprocessors
    preprocess: [
        mdsvex(mdsvexConfig),
        vitePreprocess(),
    ],

    ...

};

mdsvex.config.js

Configure the remark plugins:

const config = defineConfig({

    ...

    remarkPlugins: [
        ...
        [
            remarkImagetools,
            {
                debug: Debug.None,
                presets: [
                    {
                        name: "mobile",
                        width: 300
                    }
                ]
            }
        ],
        [
            remarkSvelteAutoImport,
            {
                debug: ['ScriptBefore', 'ScriptAfter'],
                scriptTS: true,
                directories: [
                    'src/lib/components/'
                ],
                localComponents: {
                    'src/lib/': '$lib'
                },
                patterns: [
                    '**/*.svelte',
                    '**/*.svx'
                ]
            }
        ],
        [
            remarkAutolinker,
            {
                debug: 'Default',
                all: true,
                caseInsensitive: true,
                links: [
                    { key: 'Java', link: 'https://www.java.com/de/' },
                    { key: 'Spring', link: 'https://spring.io/' },
                    { key: 'Spring boot', link: 'https://spring.io/projects/spring-boot' }
                ]
            }
        ]
        ...
    ],

});