Custom demos dir

This commit is contained in:
2023-03-03 09:13:09 +01:00
parent 2b4732a34b
commit 5242577179
16 changed files with 10323 additions and 1 deletions

View File

@@ -55,7 +55,31 @@ Garlic.peal(document);
And all is done! And all is done!
## Astro ## Astro
Coming soon :)
With Astro, you just need to import the `Garlic` and `Clove` components into your layout:
```astro
import {Garlic, Clove} from 'garlic-astro';
---
<Garlic>
<!DOCTYPE html>
<html lang="en">
<head>
<title>{title}</title>
</head>
<body>
<Clove>
<slot />
</Clove>
</body>
</html>
</Garlic>
```
Ideally, `Garlic` should wrap the entire page, and `Clove` should wrap the content you want to protect. You can also use `Clove` multiple times, if you want to protect different parts of your page.
You can then use the layout in `.astro` or `.mdx` files, and the content will be protected.
# Why? # Why?
AI needs data, your website might end-up in the dataset it uses for training. Dont want that? Garlic should help :) AI needs data, your website might end-up in the dataset it uses for training. Dont want that? Garlic should help :)

View File

@@ -0,0 +1,4 @@
{
"recommendations": ["astro-build.astro-vscode"],
"unwantedRecommendations": []
}

View File

@@ -0,0 +1,11 @@
{
"version": "0.2.0",
"configurations": [
{
"command": "./node_modules/.bin/astro dev",
"name": "Development server",
"request": "launch",
"type": "node-terminal"
}
]
}

File diff suppressed because it is too large Load Diff

View File

Before

Width:  |  Height:  |  Size: 873 B

After

Width:  |  Height:  |  Size: 873 B