Skip to content

Svelte

Use @golar/svelte to add Svelte support to Golar.

Make sure svelte is installed in your project.

Then install the Golar plugin:

Terminal window
npm i -D @golar/svelte

Add the plugin import to golar.config.ts:

golar.config.ts
import { defineConfig } from 'golar/unstable'
import '@golar/svelte'
export default defineConfig({})

Once the plugin is registered, run Golar in the default mode:

Terminal window
npx golar

This command loads golar.config.ts, runs linting, and then type-checks your project files.

Golar’s Svelte support is built on the official svelte2tsx package.