@nmpilot/scssrs

1.0.3 • Public • Published

Welcome to SCSSRS

Scary name, awesome module.

  • This is a lightweight on-demand in-browser scss to css converter.
  • Scssrs uses dart-sass at its core, along with a web-worker mechanism to
  • Compile browser side scss <script> templates into <style> tags.

Usage

<script type="module" src="node_modules/@nmpilot/scssrs/index.js"></script>

Import the module on your page.

<script type="text/plain" data-scssrs>
    $color: blue;
    body {
        background-color: $color;
    }
</script>

data-scssrs is a required attribute

The above scss code will be replaced by css:

<style>
  body {
    background-color: blue; 
  }
</style>

Buy Me A Coffee

Package Sidebar

Install

npm i @nmpilot/scssrs

Weekly Downloads

0

Version

1.0.3

License

MIT

Unpacked Size

3.33 kB

Total Files

6

Last publish

Collaborators

  • newmediapilot