You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+29-4Lines changed: 29 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@
4
4
5
5
MistCSS lets you create reusable visual components without JavaScript or TypeScript (_think about it for a second... no JS/TS needed_).
6
6
7
-
Leverage native HTML and CSS, get type safety and auto completion. Just clean and efficient styling.
7
+
Leverage native HTML and CSS, get type safety and autocomplete. Just clean and efficient styling.
8
8
9
9
<imgwidth="1116"alt="Screenshot 2024-11-01 at 03 47 44"src="https://github.com/user-attachments/assets/74aea071-be00-4d03-b43a-e46d6282e4b5">
10
10
@@ -109,6 +109,9 @@ import './mist.css'
109
109
110
110
Absolutely, MistCSS is pure HTML and CSS, generating only `mist.d.ts`, so there are no limitations. You can integrate any CSS framework seamlessly. Here are a few examples to get you started:
111
111
112
+
> [!IMPORTANT]
113
+
> For the best experience, set up Tailwind IntelliSense in your editor. Refer to [Tailwind's editor setup guide](https://tailwindcss.com/docs/editor-setup).
> `data-component` is just a naming convention. Feel free to use any attribute, like `data-style='button'` or `data-button`. It’s simply a way to differentiate between components using the same tag.
217
235
236
+
### How to split my code?
237
+
238
+
You can use CSS [@import](https://developer.mozilla.org/en-US/docs/Web/CSS/@import). For example, in your `mist.css` file:
239
+
240
+
```css
241
+
@import'./button.css'
242
+
```
218
243
219
244
### How to build complex components?
220
245
@@ -242,7 +267,7 @@ export function Card({ title, children }) {
242
267
> [!TIP]
243
268
> To indicate that these styles aren't meant to be used outside of `Card`, you can name them `data-p-component` (`p` for `private`) or use another naming convention.
0 commit comments