aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--README.md55
1 files changed, 55 insertions, 0 deletions
diff --git a/README.md b/README.md
index f0ea276..13bb5ea 100644
--- a/README.md
+++ b/README.md
@@ -6,6 +6,61 @@ No, [I will not add other color spaces](./documentation/FAQ.md#normal-colors).
+## Install
+
+```sh
+bun add uchu
+# or: npm install uchu / pnpm add uchu / yarn add uchu
+```
+
+
+
+## Usage
+
+### JavaScript / TypeScript
+
+```ts
+import { color, palette, reduced, yang } from "uchu";
+
+palette.blue[5]; // "oklch(54.87% 0.222 260.33)"
+color("red", 7); // "oklch(49.95% 0.195 18.34)"
+reduced.green[2]; // mid-shade green from the reduced palette
+yang; // off-white background constant
+```
+
+Types `Hue` and `Shade` are exported for narrowing palette keys.
+
+### CSS
+
+Drop the stylesheet in and use the CSS custom properties:
+
+```ts
+import "uchu/css";
+```
+
+```css
+body {
+ background-color: var(--uchu-yang);
+ border: 1px solid var(--uchu-blue-5);
+ color: var(--uchu-yin-9);
+}
+```
+
+### Sass / SCSS
+
+```scss
+@use "uchu/scss" as *;
+
+body {
+ background-color: $uchu-yang;
+ color: $uchu-yin-9;
+}
+```
+
+Prefer URL imports? See the [URL-based usage guide](./documentation/USAGE.md).
+
+
+
## Table of Contents
- [Expanded Palette](./documentation/EXPANDED.md)