New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@3yourmind/sass-node-modules-importer

Package Overview
Dependencies
Maintainers
10
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@3yourmind/sass-node-modules-importer

SASS Importer That Handles node_modules with support for Lerna, package.json style, etc.

1.0.1
latest
Source
npm
Version published
Weekly downloads
192
74.55%
Maintainers
10
Weekly downloads
 
Created
Source

@3yourmind/sass-node-modules-importer

node_modules importer for sass

Usage

`rollup.config.js:

import sassNodeModulesImporter from '@3yourmind/sass-node-modules-importer'
import scss from 'rollup-plugin-scss'

export default [
	scss({
		// passed directly to sass
		importer: sassNodeModulesImporter(),
		importer: sassNodeModulesImporter({ debug: true }),
		importer: sassNodeModulesImporter({ start: '~' }),
	}),
]
@import '~normalize.css/'; // Trailing slash is important if module ends with .css as sass will not call the importer otherwise

Supported Sources

  • (recursive) parent node_modules
  • package.json style property
  • files ending with importExtensions
  • index.css

Options

namedefaulttypedescription
debugfalsebooleanEnable debug logs
indexExtensions['.css', '.sass', '.scss']string[]Extensions to resolve when extension is omitted. Will prefer based on order.
start~stringPrefix string/char to refer to node_modules folders

Keywords

sass

FAQs

Package last updated on 22 Aug 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts