Skip to content

JSS plugin that allows to write camel cased rule properties

License

Notifications You must be signed in to change notification settings

vass-david/jss-camel-case

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JSS logo

JSS plugin that allows to write camel cased rule properties

Internally it converts everything back to dash separated names.

Make sure you read how to use plugins in general.

Demo - JSS

![Gitter](https://badges.gitter.im/Join Chat.svg)

Usage example

import jss from 'jss'
import camelCase from 'jss-camel-case'

jss.use(camelCase())

let sheet = jss.createStyleSheet({
  container: {
    fontSize: '20px',
    zIndex: 1,
    lineHeight: 1.2
  }
})
console.log(sheet.toString())
.jss-0-0 {
  font-size: 20px;
  z-index: 1;
  line-height: 1.2;
}
console.log(sheet.classes)
{ container: "jss-0-0" }

Issues

File a bug against cssinjs/jss prefixed with [jss-camel-case].

Run tests

npm i
npm run test

License

MIT

About

JSS plugin that allows to write camel cased rule properties

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 85.9%
  • HTML 14.1%