# CodeSnippet

Render inline or block code examples with beautiful syntax highlighting. Perfect for showing off your elegant, bug-free (hopefully) code.

## Notes

- Use block mode for commands and copyable examples. Because let's face it, we all just copy-paste from documentation anyway.
- Keep snippets focused on the main happy path. Don't include 50 lines of boilerplate if you don't have to.
- Make sure the language prop matches the code, or the syntax highlighting will look like a modern art masterpiece (and not in a good way).



## Example

```astro
<CodeSnippet variant="block" language="ts" code={snippet} />
```
