Skip to content

Commit

Permalink
Merge pull request #22 from ff6347/docs/readme
Browse files Browse the repository at this point in the history
docs(README): List features and aim
  • Loading branch information
ff6347 authored Nov 12, 2023
2 parents 75dcf64 + a2f1d25 commit 6c813d8
Showing 1 changed file with 17 additions and 1 deletion.
18 changes: 17 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,15 @@
<!-- ALL-CONTRIBUTORS-BADGE:END -->

Small experiment to have a code sandbox for testing p5.js code. Based on [this blog](https://joyofcode.xyz/create-a-coding-sandbox) post "Create a JavaScript Code Sandbox" by Matija.
The idea is to be able to build a documentation page for sketches produced during seminars, like in my seminar [gestalten-in-code](https://interface.fh-potsdam.de/gestalten-in-code/) but have all the sketches editable in the sandbox.

Current feature set is limited but it can:

- Save changes to local storage
- Control via component prop if changes should be saved to local storage
- Control via URL SearchParameters if the local storage should be disabled

See [@ff6347 p5js code sandbox project for planned features](https://github.com/users/ff6347/projects/2/views/1)

## Development

Expand All @@ -22,14 +31,21 @@ Inside of your Astro project, you'll see the following folders and files:
│ └── favicon.svg
├── src/
│ ├── components/
│ │ └── Card.astro
│ │ └── sandbox.css // the components css
│ │ └── Sandbox.tsx // the component to load in pages
│ ├── hooks/
│ │ └── local-storage.ts // the local storage customHook
│ ├── hooks/
│ │ └── iframe-source.ts // the html for the iframe
│ ├── layouts/
│ │ └── Layout.astro
│ └── pages/
│ └── index.astro
└── package.json
```

## Astro Docs

Astro looks for `.astro` or `.md` files in the `src/pages/` directory. Each page is exposed as a route based on its file name.

There's nothing special about `src/components/`, but that's where we like to put any Astro/React/Vue/Svelte/Preact components.
Expand Down

0 comments on commit 6c813d8

Please sign in to comment.