Using Components
To use a Sprout component:
- Copy and paste the component snippet
- For HTML files, use the HTML snippet
- For React or Next.js files, use the JSX snippet
<button class="btn">๐</button>
- Add optional classes if nessecary
<button class="btn rounded md darker">๐</button>
Options
Clicking on an optional class variation, ex. variation1
or square
in the below example, will copy it to your clipboard for easy pasting.
Example Componentโ
- Preview
- HTML
- JSX
<button class="btn rounded md darker">HTML</button>
<button className="btn rounded md darker">REACT</button>
Primary Colorโ
- If a color option is not specified, components will be set to the
primary
color. In the documentation examples, primary is light blue. - Set your own primary hex color with the command
npx sproutcss --primary #6daebe