mirror of
https://github.com/velocitatem/garlic.git
synced 2026-05-31 16:53:37 +00:00
Custom demos dir
This commit is contained in:
26
README.md
26
README.md
@@ -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 :)
|
||||||
|
|||||||
4
demos/astro/strong-singularity/.vscode/extensions.json
vendored
Normal file
4
demos/astro/strong-singularity/.vscode/extensions.json
vendored
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
{
|
||||||
|
"recommendations": ["astro-build.astro-vscode"],
|
||||||
|
"unwantedRecommendations": []
|
||||||
|
}
|
||||||
11
demos/astro/strong-singularity/.vscode/launch.json
vendored
Normal file
11
demos/astro/strong-singularity/.vscode/launch.json
vendored
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
{
|
||||||
|
"version": "0.2.0",
|
||||||
|
"configurations": [
|
||||||
|
{
|
||||||
|
"command": "./node_modules/.bin/astro dev",
|
||||||
|
"name": "Development server",
|
||||||
|
"request": "launch",
|
||||||
|
"type": "node-terminal"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
10283
demos/astro/strong-singularity/package-lock.json
generated
Normal file
10283
demos/astro/strong-singularity/package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load Diff
|
Before Width: | Height: | Size: 873 B After Width: | Height: | Size: 873 B |
Reference in New Issue
Block a user