Skip to content

hz2/pub.css

Repository files navigation

Open in VS Code NPM Package npm npm Docker Package Docker Image Version GitHub code size in bytes GitHub last commit

A minimal and classful Public CSS toolkit. it helps you build pages easily

💡 find the classless one.

Logo:

logo

Useage:

  • Install
npm install pub.css
  • For Less
@import "~pub.css/less/index.less";
  • For Scss
@import "~pub.css/scss/index.scss";
  • css bundle
@import "~pub.css/css/index.css";
  • main.js
import "pub.css/css/index.css";
  • docker start a service
docker run --name some-pubcss -d -p 8012:80 hzsq/pub.css

proxy localhost:8012 as /pubcss

<link rel="stylesheet" type="text/css" href="/pubcss/css/index.css" />
  • CDN
<link
  rel="stylesheet"
  type="text/css"
  href="https://cdn.jsdelivr.net/npm/pub.css/css/index.css"
/>

or

<link
  rel="stylesheet"
  type="text/css"
  href="https://unpkg.com/pub.css/css/index.css"
/>

Quick Reference

prefix short for
.c{value} color
.bgc{value} background color
.w{num} width
.h{num} height
.sq{num} square ( width & height )
.wp{num} width percentage
.hp{num} height percentage
.fz{num} font size
.fw{num} font weight
.m{num} margin
.p{num} padding
.ml{num} margin left
.px{num} padding horizontal ( x axis)
.my{num} margin vertical ( y axis)

Document