Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/timthedev07/distinct.css
Command line utility for finding duplicate or conflicting CSS rules either in a file or a directory. Supports detecting unused CSS based on HTML files. An awesome choice for CSS optimization with a nice command line UI.
https://github.com/timthedev07/distinct.css
cli command-line css nodejs optimization utility
Last synced: 3 days ago
JSON representation
Command line utility for finding duplicate or conflicting CSS rules either in a file or a directory. Supports detecting unused CSS based on HTML files. An awesome choice for CSS optimization with a nice command line UI.
- Host: GitHub
- URL: https://github.com/timthedev07/distinct.css
- Owner: timthedev07
- License: mit
- Created: 2021-07-18T15:28:36.000Z (over 3 years ago)
- Default Branch: staging
- Last Pushed: 2021-08-30T12:44:54.000Z (over 3 years ago)
- Last Synced: 2023-12-07T12:03:15.561Z (about 1 year ago)
- Topics: cli, command-line, css, nodejs, optimization, utility
- Language: TypeScript
- Homepage:
- Size: 412 KB
- Stars: 10
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## About
A command line app for finding and removing duplicate or conflicting css rules in a given file or directory.
## Simply
```bash
npx distinct.css
```## Installation
Install globally:
```bash
yarn global add distinct.css
```Install as a dev dependency for your project:
```bash
yarn add -D distinct.css
```## Get Started
```bash
distinct.css -f [file/directory]
```## Command Line Usage
```
Usage: distinct.css -f [path]Options:
-f, -d, --file, --directory File/directory to check [string] [required]
-c, --showConflict Show conflicting rules [boolean] [default: false]
-r, --recursive Recursively search in a directory
[boolean] [default: true]
-u, --detectUnused Check for unused css rules. Note that if this
flag is passed, all the other ones would be
ignored since it behaves differently.
[boolean] [default: false]
-h, --help Show help [boolean]
-v, --version Show version number [boolean]Examples:
distinct.css -f button.css searches for duplicate css rules in file
button.cssdistinct.css -rf css/ recursively searches for duplicate css
rules in the css directorydistinct.css -cf conflicts.css searches for duplicate and conflicting
css rules in conflicts.cssindex.ts -u detect unused css, more information will be
prompt when command executes
```