Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://atk.github.io/solid-blocks/
UI building blocks for SolidJS.
https://atk.github.io/solid-blocks/
components solidjs
Last synced: 6 days ago
JSON representation
UI building blocks for SolidJS.
- Host: GitHub
- URL: https://atk.github.io/solid-blocks/
- Owner: atk
- Created: 2021-07-07T08:55:57.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-01-08T22:04:24.000Z (almost 2 years ago)
- Last Synced: 2024-10-10T02:36:48.244Z (30 days ago)
- Topics: components, solidjs
- Language: TypeScript
- Homepage: https://atk.github.io/solid-blocks/
- Size: 1.19 MB
- Stars: 83
- Watchers: 5
- Forks: 3
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-solid-js - Solid Blocks - UI building blocks for SolidJS. (📦 Components & Libraries / Frameworks & Component Libraries)
README
# Solid-Blocks
UI building blocks for [SolidJS](https://solidjs.com)
## Core concepts
### Valuable components instead of components without added value
Wrapping elements like headers, text, or images in custom Components is just wasteful. Components will only be provided if they have added value over their native elements. The added value may be
- user experience
- accessibility
- developer experience
- performanceIf none of these advantages can be provided, it is preferable to use native HTML elements or SolidJS' abilities like Portal effectively.
### Components with style instead of styled components
Directly using CSS is frowned upon nowadays, but not rightfully so. Well crafted CSS will easily outperform styled components. It should do so with
- minimal bleeding (class prefix `sb-[component]`, CSS reset, basic styles, theme variables)
- semantic class names, i.e. `.primary.sb-button`
- careful consideration of a11y
- works as much as possible in non-JS environments (SSR)
- theme-able, dark mode, inline mode switch possible
- TODO: responsive layout### Usage
```shell
yarn
yarn dev
```To use the components
```tsx
import { Accordion, AccordionHeader } from "solid-blocks";const MyApp = () => {
return (
Accordion
Hidden
);
};
```