You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

jss-camel-case

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jss-camel-case

JSS plugin that allows to write camel cased rule properties

6.1.0
latest
Source
npmnpm
Version published
Weekly downloads
121K
-32.11%
Maintainers
1
Weekly downloads
 
Created

What is jss-camel-case?

The jss-camel-case npm package is a plugin for JSS (JavaScript Style Sheets) that converts camelCased property names to dash-separated (kebab-case) names. This is useful for writing CSS-in-JS styles in a more JavaScript-friendly syntax while ensuring compatibility with CSS standards.

What are jss-camel-case's main functionalities?

Convert camelCase to kebab-case

This feature allows you to write styles in camelCase and have them automatically converted to kebab-case. In the example, `backgroundColor` and `fontSize` are converted to `background-color` and `font-size` respectively.

const jss = require('jss').default;
const camelCase = require('jss-camel-case').default;

jss.use(camelCase());

const styles = {
  button: {
    backgroundColor: 'blue',
    fontSize: '14px'
  }
};

const sheet = jss.createStyleSheet(styles).attach();
console.log(sheet.toString());

Other packages similar to jss-camel-case

Keywords

cssinjs

FAQs

Package last updated on 08 Feb 2018

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