diff --git a/site/docs/community/snippets/boilerplate.md b/site/docs/community/snippets/boilerplate.md index a2ed0d0e..3cb4cb8b 100644 --- a/site/docs/community/snippets/boilerplate.md +++ b/site/docs/community/snippets/boilerplate.md @@ -13,11 +13,13 @@ This guide explains **how to structure, write, and submit a snippet** so it appe ## 1️⃣ Directory Structure Each snippet should live in its **own folder** under the appropriate category: +Any images or downloadable modules should reside in the assets folder ```bash docs/community/snippets/// index.md <-- main snippet file /assets/demo.gif <-- optional visual demonstration or static assets +/assets/myComponent.ts ``` **Categories** might include: @@ -34,7 +36,7 @@ docs/community/snippets/ui-hud/button-effects/index.md docs/community/snippets/ui-hud/button-effects/assets/demo.gif ``` -Your markdown file should have a header and include this content: +## 2️⃣ Your markdown file should have a header and include this content: ``` //index.md diff --git a/site/docs/community/snippets/components-systems/basic-healthbar/healthbar.ts b/site/docs/community/snippets/components-systems/basic-healthbar/assets/healthbar.ts similarity index 100% rename from site/docs/community/snippets/components-systems/basic-healthbar/healthbar.ts rename to site/docs/community/snippets/components-systems/basic-healthbar/assets/healthbar.ts diff --git a/site/docs/community/snippets/components-systems/basic-healthbar/lifebar.png b/site/docs/community/snippets/components-systems/basic-healthbar/assets/lifebar.png similarity index 100% rename from site/docs/community/snippets/components-systems/basic-healthbar/lifebar.png rename to site/docs/community/snippets/components-systems/basic-healthbar/assets/lifebar.png diff --git a/site/docs/community/snippets/components-systems/basic-healthbar/index.md b/site/docs/community/snippets/components-systems/basic-healthbar/index.md index 46d32e65..83b03ff7 100644 --- a/site/docs/community/snippets/components-systems/basic-healthbar/index.md +++ b/site/docs/community/snippets/components-systems/basic-healthbar/index.md @@ -26,9 +26,9 @@ The `HealthBar` component provides a **visual health bar** that can be attached You can download the full TypeScript module here: -[Download HealthBar.ts](./HealthBar.ts) +[Download HealthBar.ts](./assets/healthbar.ts) -[LifeBar.png](./lifebar.png) +[LifeBar.png](./assets/lifebar.png) ```ts import { Actor, Engine, Scene } from 'excalibur';