Skip to content

Commit

Permalink
docs: improve onboarding
Browse files Browse the repository at this point in the history
  • Loading branch information
friedrith committed Aug 10, 2024
1 parent b7eb154 commit 0e5046c
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions packages/style-tailwind/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,22 +14,20 @@ pnpm add @design-system-hub/tailwind

This package is designed to work with the [dshub](../node-cli/README.md) CLI tool.

Once you have run `dshub pull` and have the file `src/tailwind.css` in your project, you can set up tailwind to use CSS variables automatically.
1. Run `dshub pull` in your project. It will generate the file `src/tailwind.css`.

Import the file `src/tailwind.css` your index.ts
2. Import the file `src/tailwind.css` your index.ts

```ts
// in your index.ts

import './tailwind.css`

//...

```

Then you can override the tailwind config with the generated tokens.

```ts
// tailwind.config.js
// in your tailwind.config.js

import { generateTailwindConfig } from '@design-system-hub/tailwind'

Expand All @@ -40,3 +38,9 @@ module.exports = {
plugins: [],
}
```

You can find an example in [with-tokens-tailwind](../../examples/with-tokens-tailwind).

```
```

0 comments on commit 0e5046c

Please sign in to comment.