All Projects β†’ postcss-rs β†’ postcss-rs

postcss-rs / postcss-rs

Licence: MIT License
πŸš€ Fast and 100% API compatible postcss replacer, built in Rust

Programming Languages

rust
11053 projects
javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to postcss-rs

Postcss
Transforming styles with JS plugins
Stars: ✭ 25,612 (+6086.47%)
Mutual labels:  postcss, ast
Astexplorer
A web tool to explore the ASTs generated by various parsers.
Stars: ✭ 4,330 (+945.89%)
Mutual labels:  postcss, ast
Reshape
πŸ’  transform html with javascript plugins
Stars: ✭ 314 (-24.15%)
Mutual labels:  postcss, ast
Astexplorer.app
https://astexplorer.net with ES Modules support and Hot Reloading
Stars: ✭ 65 (-84.3%)
Mutual labels:  postcss, ast
valast
Convert Go values to their AST
Stars: ✭ 251 (-39.37%)
Mutual labels:  ast
ast ninja
The Elixir AST explorer
Stars: ✭ 59 (-85.75%)
Mutual labels:  ast
astra
Astra: a Java tool for analysing and refactoring Java source code
Stars: ✭ 35 (-91.55%)
Mutual labels:  ast
asty
Abstract Syntax Tree (AST) Data Structure
Stars: ✭ 28 (-93.24%)
Mutual labels:  ast
tailpress
A Tailwind CSS enabled Underscores theme
Stars: ✭ 60 (-85.51%)
Mutual labels:  postcss
XT-TailwindCSS-Starter
A Tailwind CSS Starter. Based on Tailwind CSS, Webpack, PostCSS, and cssnano. Fully optimized for top performance.
Stars: ✭ 19 (-95.41%)
Mutual labels:  postcss
ast-builder
Build your ASTs directly from code
Stars: ✭ 18 (-95.65%)
Mutual labels:  ast
eleventy solo starter njk
Further development suspended as of 2021-09-11. Please refer instead to https://www.11ty.dev/docs/starter/ for a wide selection of other Eleventy starter sets.
Stars: ✭ 22 (-94.69%)
Mutual labels:  postcss
parseclj
Clojure Parser for Emacs Lisp
Stars: ✭ 44 (-89.37%)
Mutual labels:  ast
postcss-each
PostCSS plugin to iterate through values
Stars: ✭ 93 (-77.54%)
Mutual labels:  postcss
jsdast
JSDoc Abstract Syntax Tree
Stars: ✭ 20 (-95.17%)
Mutual labels:  ast
postcss-inline-base64
PostCSS plugin used to replace value inside of url function to base64
Stars: ✭ 23 (-94.44%)
Mutual labels:  postcss
tsquery-playground
Playground for TSQuery
Stars: ✭ 30 (-92.75%)
Mutual labels:  ast
vw-layout
Mobile website layout with viewport units
Stars: ✭ 47 (-88.65%)
Mutual labels:  postcss
antd-color-replacer
ι€‚η”¨δΊŽ webpack ηŽ―ε’ƒδΈ‹ ηš„ δΈ»ι’˜εˆ‡ζ’ζ’δ»Ά
Stars: ✭ 22 (-94.69%)
Mutual labels:  postcss
esvalid
confirm that a SpiderMonkey format AST represents an ECMAScript program
Stars: ✭ 24 (-94.2%)
Mutual labels:  ast

postcss-rs

πŸš€ Fast and 100% API compatible postcss replacer, built in Rust

⚠️ DO NOT USE. STILL WORK IN PROGRESS.

Performance Improvement

Run benchmark:

cargo build --release --locked --bin "benchmark*"
cargo run --release --bin benchmark

Tokenizer (Compare with Node.js v16.13.0):

js:   0.71s user 0.09s system 152% cpu 0.619 total
rust: 0.03s user 0.01s system  93% cpu 0.039 total
file tailwind-components.css bootstrap-reboot.css bootstrap-grid.css bootstrap.css tailwind.css tailwind-dark.css
size 2.8K 7.4K 71K 201K 3.5M 5.8M
js 1.813ms 2.380ms 11.856ms 33.919ms 167.309ms 224.577ms
rust 0.019ms 0.037ms 0.191ms 0.721ms 9.624ms 15.743ms
~ 95x 64x 61x 47x 17x 14x

Parser (Compare with Node.js v16.13.0):

js:   1.45s user 0.16s system 183% cpu 0.881 total
rust: 0.10s user 0.03s system  97% cpu 0.137 total
file tailwind-components.css bootstrap-reboot.css bootstrap-grid.css bootstrap.css tailwind.css tailwind-dark.css
size 2.8K 7.4K 71K 201K 3.5M 5.8M
js 4.405ms 4.203ms 33.344ms 55.749ms 356.345ms 441.832ms
rust 0.070ms 0.088ms 1.016ms 2.220ms 45.112ms 68.663ms
~ 63x 47x 33x 25x 8x 6x

πŸŽ‰ Welcome to contribute, here is a guide:

git checkout main
cargo bench -- --save-baseline main

Create a baseline, Then do some optimization work here.

git checkout feature  ## `feature` is your branch

Compare against the main baseline.

cargo bench -- --baseline main

License

postcss-rs is released under the MIT License. See the LICENSE file in the project root directory for details.

ACKNOWLEDGEMENT

The project is based on the wonderful work of Andrey Sitnik(@ai) 's postcss, which is under MIT License(See HERE), Great thanks to Mr. Sitnik and other contributors' work.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].