Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

rework

Package Overview
Dependencies
Maintainers
2
Versions
45
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rework

CSS manipulations built on CSSOM

  • 0.19.0
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1.1M
decreased by-8.02%
Maintainers
2
Weekly downloads
 
Created

What is rework?

Rework is a plugin framework for CSS preprocessing. It allows you to manipulate CSS using JavaScript, providing a way to transform stylesheets with various plugins.

What are rework's main functionalities?

CSS Parsing

Rework can parse CSS strings into an Abstract Syntax Tree (AST), which can then be manipulated programmatically.

const rework = require('rework');
const css = 'body { color: red; }';
const ast = rework(css).toString();
console.log(ast);

CSS Transformation

Rework allows you to transform CSS using plugins. For example, the rework-npm plugin lets you import CSS from npm packages.

const rework = require('rework');
const reworkNPM = require('rework-npm');
const css = '@import "normalize.css";';
const output = rework(css).use(reworkNPM()).toString();
console.log(output);

Vendor Prefixing

Rework can automatically add vendor prefixes to CSS properties using plugins like rework-plugin-prefix.

const rework = require('rework');
const reworkPrefix = require('rework-plugin-prefix');
const css = 'body { display: flex; }';
const output = rework(css).use(reworkPrefix('webkit')).toString();
console.log(output);

Other packages similar to rework

Keywords

FAQs

Package last updated on 23 Dec 2013

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc