docs: move TW CSS infos to CSS

This commit is contained in:
madrilene 2025-11-19 18:44:11 +01:00
parent 96a6ed7b2e
commit f843ccca01
2 changed files with 17 additions and 3 deletions

View file

@ -36,4 +36,20 @@ It makes visible when your code[ wrapped in `<is-land>` elements](https://github
### Cascade layers
We now use cascade layers! Up until now, I used the `:where()` pseudo-class to create low specificity selectors for the reset and compositions. [Mayank inspired me](https://mayank.co/blog/css-reset-layer/) to change to cascade layers. We have two major bundles of CSS: everything included in "global" In `src/assets/css/global/global.css` is now organized in cascade layers. The "local" bundle is for per-page or component CSS, and does not use cascade layers - it has thus a higher specificity, independent of any selector specificity in the global CSS.
We now use cascade layers! Up until now, I used the `:where()` pseudo-class to create low specificity selectors for the reset and compositions. [Mayank inspired me](https://mayank.co/blog/css-reset-layer/) to change to cascade layers. We have two major bundles of CSS: everything included in "global" In `src/assets/css/global/global.css` is now organized in cascade layers. The "local" bundle is for per-page or component CSS, and does not use cascade layers - it has thus a higher specificity, independent of any selector specificity in the global CSS.
### Tailwind CSS
You will find that Tailwind CSS does not work as you might expect here. I explain this in [one of the blog posts](/blog/what-is-tailwind-css-doing-here/).
If you are working with **VS Code** I recommend installing the [Tailwind CSS IntelliSense](https://marketplace.visualstudio.com/items?itemName=bradlc.vscode-tailwindcss) addon, as it works also for the custom utility classes.
If the IntelliSense does not seem to work in Nunjucks files, try adding this to your VS Code settings:
```json
"tailwindCSS.includeLanguages": {
"jinja-html": "html",
"jinja": "html",
"njk": "html"
},
```

View file

@ -11,8 +11,6 @@ You can use this starter as a template for your blog and you are ready to go! Bu
- edit your personal details and social media in `src/_data/personal.yaml`.
- Open `src/assets/css/global/blocks/external-link.css`. Replace "eleventy-excellent.netlify.app" with your own domain. This is about the external link indicators, they are matched with your domain. If you don't want to use external link indicators, feel free to delete the whole style rule. You can also add the class `no-indicator` to any anchor element you want to except from this rule.
If you are working with **VS Code** I recommend installing the "Tailwind CSS IntelliSense" addon, as it works also for our custom utility classes. That said, you will find that Tailwind CSS does not work as you might expect. I explain this in [one of the blog posts](/blog/what-is-tailwind-css-doing-here/).
The [blog posts](/blog/) also explain / show some features that aren't covered here.
## "Docs" lol