Socket
Book a DemoInstallSign in
Socket

@plotdb/csscope

Package Overview
Dependencies
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@plotdb/csscope

add scope to any css code

Source
npmnpm
Version
0.0.1
Version published
Weekly downloads
28
-24.32%
Maintainers
1
Weekly downloads
 
Created
Source

csscope

add custom scope to any css. Use browser thus only works in browsers.

Usage

include csscope.js, then convert css via following:

var scopedCSS = csscope("desired-scope-name", "your-css-code")
scopedCSS = csscope({css: "your-css-code", scope: "desired-scope-name"}) # option in object

or, create a converter to convert:

scoper = new csscope.converter();
var scopedCSS = scoper.convert({ ... });

Todo

Test against all major browsers.

License

MIT

FAQs

Package last updated on 07 Dec 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