From 7b28a620a9dee90132c5c2c68f86aaa0ab3a0006 Mon Sep 17 00:00:00 2001 From: Felix Roos Date: Fri, 18 Feb 2022 13:45:15 +0100 Subject: [PATCH] build tutorial after repl --- repl/README.md | 11 ----------- repl/package.json | 5 +++-- repl/src/useCycle.ts | 2 +- 3 files changed, 4 insertions(+), 14 deletions(-) diff --git a/repl/README.md b/repl/README.md index db8fde66..e399d2df 100644 --- a/repl/README.md +++ b/repl/README.md @@ -1,16 +1,5 @@ # Strudel REPL -## TODO - -### mini notation ([krill docs](https://github.com/Mdashdotdashn/krill#general-principles)) - -- "@" aka elongation / weight: how to write in strudel? -- "%" fixed step: how to write in strudel? -- "struct" not sure how to do this -- "c3(5,8)" bjorklund algorithm -- more [mini notation features](https://tidalcycles.org/docs/patternlib/tutorials/mini_notation) -- not tested - ## Default Snowpack Readme > ✨ Bootstrapped with Create Snowpack App (CSA). diff --git a/repl/package.json b/repl/package.json index 68108c02..bb328f50 100644 --- a/repl/package.json +++ b/repl/package.json @@ -1,13 +1,14 @@ { "scripts": { "start": "snowpack dev", - "build": "snowpack build && cp ./public/.nojekyll ../docs", + "build": "snowpack build && cp ./public/.nojekyll ../docs && npm run build-tutorial", "static": "npx serve ../docs", "test": "web-test-runner \"src/**/*.test.tsx\"", "format": "prettier --write \"src/**/*.{js,jsx,ts,tsx}\"", "lint": "prettier --check \"src/**/*.{js,jsx,ts,tsx}\"", "peggy": "peggy -o krill-parser.js --format es ./krill.pegjs", - "tutorial": "parcel src/tutorial/index.html" + "tutorial": "parcel src/tutorial/index.html", + "build-tutorial": "parcel build src/tutorial/index.html --dist-dir ../docs/tutorial --public-url /tutorial --no-optimize --no-scope-hoist" }, "dependencies": { "@tonaljs/tonal": "^4.6.5", diff --git a/repl/src/useCycle.ts b/repl/src/useCycle.ts index 9c9e8fe2..cd9ea2cb 100644 --- a/repl/src/useCycle.ts +++ b/repl/src/useCycle.ts @@ -58,7 +58,7 @@ function useCycle(props: UseCycleProps) { useEffect(() => { ready && query(); - }, [onEvent, onSchedule, onQuery]); + }, [onEvent, onSchedule, onQuery, ready]); const start = async () => { console.log('start');