A collection of hackable templates to learn p5.play.
Compiled by Matteo + contributors.
- Fork this repo.
- Add your hackable plaything to
index.html
. More on this below. - Commit + push to your fork.
- Create a pull request.
- Done :)
- Open
index.html
- Find the
plaything template
. - Copy-paste it where you want your plaything to appear.
- Uncomment the
<article> ... </article>
block. - Write a short description for your plaything. Use it in:
- the
<p class="description">
- the
<img alt="">
alt text - the
<!-- -->
comment above the<article>
- the
- List the learning points of your plaything in the
<div class="learning-goals">
. - Add links to:
- view your plaything
- remix your plaything (source-code)
- Take a screenshot / animated gif of your plaything and link it to
<img src="">
. A 3x2 image ratio (eg: 600x400 px) would be nice.
You just open index.html
in your browser, right? Unfortunately, p5 won't be able to load images and sounds with this method (as the browser doesn't have access to all your files by default).
So you need to start a web server on the folder where your plaything lives (or one of its parent folders):
- Open Terminal
- Navigate to this project folder
- Type
python -m SimpleHTTPServer 1983
- Open your favourite browser and go to
http://localhost:1983