Rollup plugin that extracts SCSS/SASS styles and embeds them as CSSResult for lit-html/lit-element components. Currently at version 0.3.3. This plugin replaces node-sass with sass in v3, and changed the default template export from TemplateResult to CSSResult in v2. It supports custom compilers and processors, but note that the active version (0.3.3) is old and the author recommends using newer alternatives like @chialab/postcss-lit. The plugin is in maintenance mode with infrequent releases.
npm install rollup-plugin-lit-html-styleVerified import paths — ran on the pinned version, not inferred.
Configure Rollup to process .scss files and embed them as CSSResult in lit-html components.
If you need inline style in template, use unsafeHTML or custom template function.
Install sass as a peer dependency: npm install sass.
Use './_partial.scss' instead of '_partial.scss'.
Consider using @chialab/postcss-lit or rollup-plugin-webcomponent-style.
npm install sass --save-dev
Change 'import { style } from './style.scss' to 'import style from './style.scss'