🕶 Add SASS to Svelte

This is an adder for svelte-add; you should read its README before continuing here.

➕ Adding SASS

This adder's codename is sass, and can be used like so:

npx svelte-add@latest sass

🏞 Supported environments

This adder supports SvelteKit and Vite-powered Svelte apps (all the environments svelte-add currently supports).

⚙️ Options

This adder doesn't take any options of its own.

🛠 Using SASS

After the adder runs,

  • You can write SASS syntax in the style lang="sass" blocks in Svelte files.

  • You can write SASS syntax in the src/variables.sass file.

    Variables and mixins written here are automatically available to all other SASS files and style lang="sass" blocks in Svelte files without needing to import this file.

  • You can write SASS syntax in the src/app.sass file.

    This is your global stylesheet because it will be active on every page of your site.

Top categories

Loading Svelte Themes