Skip to content

Commit e94363b

Browse files
authored
Merge branch '2.0' into 2.0
2 parents 7c6aa04 + adf1173 commit e94363b

343 files changed

Lines changed: 13315 additions & 9288 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

astro.config.mjs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import mdx from "@astrojs/mdx";
44
import tailwind from "@astrojs/tailwind";
55
import serviceWorker from "astrojs-service-worker";
66
import fast from "./src/scripts/fast-compress";
7+
import mermaid from 'astro-mermaid';
78

89
// Allow skipping compression step for faster test build times
910
// DO NOT SKIP COMPRESSION FOR DEPLOYMENT!
@@ -19,7 +20,11 @@ if (shouldSkipCompress) {
1920
export default defineConfig({
2021
site: 'https://p5js.org',
2122
compressHTML: false,
23+
legacy: {
24+
collections: true
25+
},
2226
integrations: [
27+
mermaid({autoTheme: true}),
2328
preact({
2429
compat: true,
2530
}),

docs/scripts.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,22 @@ npm run custom:dev https://github.com/yourUsername/p5.js.git#yourBranch
1616

1717
This will build the reference from your branch and start a development preview of the website. A URL will be logged in the console that you can go to in your browser to test out your changes.
1818

19+
Actually, it's also possible to test against a branch from your _local_ repo. This means you can test without first pushing to github (but you _will_ still need your changes checked into a branch, locally).
20+
21+
To do this, just supply the file-path to the local repo, instead of the url to the repo.
22+
23+
```sh
24+
npm run custom:dev path-to-local-repo#yourBranch
25+
```
26+
27+
For example, if you have a local p5.js clone repo called `p5.js` as a sibling directory to the website, you could run the following:
28+
29+
```sh
30+
npm run custom:dev ../p5.js#yourBranch
31+
```
32+
33+
### Resetting your changes
34+
1935
When you're done, you can run this command to reset your changes:
2036
```sh
2137
npm run custom:cleanup

0 commit comments

Comments
 (0)