stylescope
Why comprimise? Grab your Stylescope and create elegantly.
Last updated 5 years ago by jameswomack .
ISC · Original npm · Tarball · package.json
$ cnpm install stylescope 
SYNC missed versions from official npm registry.

Stylescope

Don't pollute. Scope your styles.

Getting Going

Please see the tests to see what works so far. This is not in a ready state yet. The tested case works, but other things you'll try may not.

const Stylescope       = require('stylescope') 

const el               = document.querySelector('section')
const scopedStyleSheet = Stylescope(el, childSelPropAssoc)

// data-attribute-based selector representing the context
scopedStyleSheet.selector  

// The <style>
scopedStyleSheet.styleEl     

// The CSSStyleSheet
scopedStyleSheet.sheet       

scopedStyleSheet.createRule  
scopedStyleSheet.pushRule    
scopedStyleSheet.pushRules  
scopedStyleSheet.deleteRule
scopedStyleSheet.deleteRules 

// The last set of indexes created
scopedStyleSheet.lastPushedRuleIndexes 

Testing

Current Tags

  • 1.0.0-alpha.0                                ...           latest (5 years ago)

1 Versions

  • 1.0.0-alpha.0                                ...           5 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 1
Dependencies (8)
Dev Dependencies (7)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |