GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - swordcss/swordcss: A powerful CSS compiler

BranchesTags
Open more actions menu

Latest commit

 

History

174 Commits
174 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
src
src
 
 
test
test
 
 
types
types
 
 
.eslintignore
.eslintignore
 
 
.eslintrc.js
.eslintrc.js
 
 
.gitignore
.gitignore
 
 
.prettierignore
.prettierignore
 
 
.travis.yml
.travis.yml
 
 
CONTRIBUTING.md
CONTRIBUTING.md
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
package-lock.json
package-lock.json
 
 
package.json
package.json
 
 
rollup.config.js
rollup.config.js
 
 
tsconfig.json
tsconfig.json
 
 

Repository files navigation

SwordCSS

A powerful CSS compiler

Build Status Coverage Status Maintainability Percentage Total alerts Language grade: JavaScript npm version

What Does This Add?

  • An easier systems for combining the styles of classes, ids, and other queries
  • The equivalent of SCSS variables, constants that can be used throughout your CSS
  • An easier way to write CSS variables

And all of that is added through valid CSS syntax!

Installation

$ npm install swordcss
# Or use Yarn
$ yarn add swordcss

Usage

const SwordCSS = require("swordcss");

const sword = SwordCSS();

sword.compile(
  ".allElem {width: 100%; height: 100%;} #elem {sw-class: allElem;}"
); // .allElem {width: 100%; height: 100%;} #elem {width: 100%; height: 100%;}

Options

{
  "useClass": true,
  "useConstant": true,
  "useId": true,
  "useQuery": true,
  "useVariable": true,
  "minify": false
}

These options are used when you initialize the SwordCSS instance.

Documentation

You can check out the documentation for this project here.

Contributing

Code Style

The code style is enforced through ESLint with the SwordCSS ESLint Config and prettier with no config.

Validate code with ESLint

$ npm run lint

Format code with prettier

$ npm run prettier
# or you can use format
$ npm run format

Tests

Tests use mocha for test running and chai for assertions. We also use nyc with Instanbul to calculate code coverage.

Run tests with mocha

$ npm test

Typescript

We use Typescript and JSDoc for static typing of our project without build tooling.

Check types

$ npm run types

Rollup Bundling

We use Rollup to bundle our code into ESM and CJS before being uploaded to NPM.

Bundle code

$ npm run build

Supporters

Stargazers repo roster for @swordcss/swordcss

Forkers repo roster for @swordcss/swordcss

About

A powerful CSS compiler

swordcss.js.org

Topics

compilercsscss-compilercss-preprocessorcss-preprocessorssupersettranspiler

Resources

Readme
MIT license

Contributing

Contributing
Activity
Custom properties

Stars

7 stars

Watchers

1 watching

Forks

2 forks
Report repository

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.