From 47ecf6b27537c26d4f33a2e3a8c84cb756ed315e Mon Sep 17 00:00:00 2001
From: Andrew Petersen
Date: Fri, 22 May 2026 14:37:45 -0400
Subject: [PATCH 01/11] rename default branch to main
---
.travis.yml | 4 ++--
README.md | 6 +++---
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/.travis.yml b/.travis.yml
index f6b0877..1355964 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -18,11 +18,11 @@ deploy:
on:
tags: true
repo: spotify/NFPlayerJS
- branch: master
+ branch: main
- provider: pages
github-token: $GITHUB_TOKEN
skip_cleanup: true
keep-history: true
local-dir: demo/dist/
on:
- branch: master
+ branch: main
diff --git a/README.md b/README.md
index 2e1c5ef..ef3ef60 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,6 @@
-
+
[](LICENSE)
@@ -135,7 +135,7 @@ To build and publish the demo to [gh-pages](playground) manually, run:
$ npm run deploy:demo:manual
```
-Otherwise the demo is actually built and deployed on each push to master.
+Otherwise the demo is actually built and deployed on each push to main.
There is also a more cut-down [debug environment](./debug-harness/index.ts) useful for debugging / developing single Scores or scripts:
@@ -152,7 +152,7 @@ $ npm run debug-harness
### Demo Deployment:
-- The demo is deployed automatically on master builds using the TravisCI gh-pages provider.
+- The demo is deployed automatically on main builds using the TravisCI gh-pages provider.
# Contributing 💖⌨️
From 6391854a62c7c1cda7642fe7cab35bace3ec258c Mon Sep 17 00:00:00 2001
From: Drew Petersen
Date: Wed, 27 May 2026 13:08:03 -0400
Subject: [PATCH 02/11] chore: modernize tooling/build to 2026 (#53)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
* chore: switch to pnpm
* chore: phase 1 — workspace + tsconfig split
- demo becomes a real pnpm workspace member; drop its npm lockfile and
hand-maintained nf-player/nf-grapher .d.ts copies
- split single tsconfig into solution + package.tsconfig + demo.tsconfig
- add MODERNIZE.md plan
* chore: phase 3 — modernize deps, build, test, lint stacks
- typescript 3.8 → 6.0, prettier 1 → 3, eslint 6 → 10 flat config, debug
4.1 → 4.4, typedoc 0.17 → 0.28, husky 4 → 9, lint-staged 10 → 17
- demo: react 16 → 19, styled-components 5 → 6, monaco 0.20 → 0.55
- add: vitest, tsdown, @arethetypeswrong/cli, publint, vite,
@vitejs/plugin-react, typescript-eslint, @eslint/js
- remove: parcel-bundler, npm-run-all, jest, ts-jest, @commitlint/*,
gh-pages, eslint-plugin-{prettier,notice}; old @typescript-eslint/*
packages replaced by combined typescript-eslint
- migrate jest → vitest (globals: true, no jsdom needed after
window.performance.now() → performance.now())
- husky v4 → v9 (.husky/pre-commit, prepare script), drop commitlint
- TS 6.0 fixes: import Debug from 'debug', Float32Array
generics in XAudioBuffer, catch(e as Error) casts
- typecheck is package-only until Phase 4 fixes demo
* chore: phase 2 — dual ESM/CJS build via tsdown
- tsdown emits ESM + CJS + per-condition .d.ts/.d.cts (points at the
package leaf tsconfig, not the root solution)
- package.json: "type": "module", sideEffects: false, per-condition
exports map, main/module/types/bin pointed at dist/, files: [dist],
prepack runs build
- CLI cleanup: drop cross-fetch (native fetch), tempy → node:fs +
randomUUID, require('../package.json') → import attribute
- index.ts re-exports split into value vs `export type` blocks; enable
verbatimModuleSyntax + isolatedModules; bulk add inline `type`
modifier via typescript-eslint consistent-type-imports autofix
- publint clean; attw deferred (its bundled TS 5.6.1-rc can't parse
Float32Array generics)
* chore: phase 4 — demo on Vite
- demo/vite.config.ts with @vitejs/plugin-react, multi-entry
(index.html + debug.html), base './' for GH Pages
- HTML moved from demo/src/ to demo/ (Vite-idiomatic layout)
- debug-harness/ folded into demo as debug.html + src/debug.ts
- Monaco.tsx collapsed from ~220 to ~85 lines (kills the 90-line
Parcel-era side-effect import wall; workers via Vite ?worker)
- React 16 → 19 fallout: createRoot, React.FC, React.ReactNode,
React.JSX.Element, drop `private state` modifier, fix CODEEditor
duplicate componentDidMount, MonacoEditor onChange defaults
- demo imports `from '../../../src'` → `from 'nf-player'` (workspace)
- expose XAudioContext from nf-player public exports (demo needs it)
- (nextRenderer as any).processor cast for FFT analyzer poke
- root `pnpm typecheck` flipped back to `tsc -b` (whole solution)
* chore: phase 5 — replace Travis with GitHub Actions
- ci.yml: push + PR — install --frozen-lockfile, typecheck, lint,
vitest, build, validate (publint), build demo
- release.yml: on release published — build/validate/test, then
`pnpm publish --provenance --access public` with NPM_TOKEN
(gated by a protected `npm` environment)
- pages.yml: push to main — build demo, deploy via
actions/{configure,upload-pages-artifact,deploy}-pages (kills the
gh-pages npm dep + branch-pushing flow)
- injection hardening: read-only default permissions, id-token/pages
scoped to the jobs that need them, persist-credentials: false on
checkout, pull_request not pull_request_target, no untrusted
${{ github.event.* }} in run blocks, concurrency cancel-stale
- third-party actions still on @v4 tags with `# TODO: SHA-pin`
markers — one Dependabot pass converts
- delete .travis.yml (stale encrypted npm token + spotify/-vs-
nativeformat/ repo mismatch)
* fix: put back monaco auto-completions
* chore: cleanup actions yaml
* chore: bring back license headers
* update README
* fix: eslint warnings
* chore: resort imports
* build: add pinact and pin workflows
* chore: cleanup
* chore: allow demo to consume package source
---
.eslintignore | 1 -
.eslintrc.js | 48 -
.github/workflows/ci.yml | 35 +
.github/workflows/pages.yml | 48 +
.github/workflows/release.yml | 34 +
.gitignore | 3 +
.husky/pre-commit | 1 +
.pinact.yaml | 5 +
.prettierrc | 3 +
.prettierrc.js | 3 -
.travis.yml | 28 -
README.md | 54 +-
debug-harness/declarations.d.ts | 23 -
demo.tsconfig.json | 19 +
demo/.npmrc | 1 -
debug-harness/index.html => demo/debug.html | 8 +-
demo/{src => }/index.html | 4 +-
demo/monaco-declarations/.gitkeep | 0
demo/nf-grapher.d.ts | 1132 --
demo/nf-player.d.ts | 210 -
demo/package-lock.json | 405 -
demo/package.json | 34 +-
demo/scripts/gen-monaco-declarations.sh | 19 +
demo/src/ExampleJSONScores.ts | 27 +-
demo/src/ExampleScripts.ts | 39 +-
demo/src/components/App.tsx | 35 +-
demo/src/components/CODEEditor/CODEEditor.tsx | 59 +-
demo/src/components/JSONEditor/JSONEditor.tsx | 29 +-
demo/src/components/Monaco.tsx | 180 +-
demo/src/components/PlayerControlBar.tsx | 11 +-
demo/src/components/PlayerWatcher.tsx | 13 +-
.../ScoreVisualizer/FileNodeMonitor.tsx | 13 +-
.../ScoreVisualizer/LoopNodeMonitor.tsx | 26 +-
.../components/ScoreVisualizer/NodePanel.tsx | 11 +-
.../ScoreVisualizer/ParamMonitor.tsx | 23 +-
.../ScoreVisualizer/SourceMonitor.tsx | 7 +-
.../ScoreVisualizer/VisualGridColumn.tsx | 15 +-
demo/src/components/ScoreVisualizer/index.tsx | 13 +-
.../WaveVisualizer/FrequencyMonitor.tsx | 1 +
.../WaveVisualizer/WaveVisualizer.tsx | 31 +-
debug-harness/index.ts => demo/src/debug.ts | 21 +-
demo/src/index.ts | 9 +-
demo/src/vite-env.d.ts | 1 +
demo/tsconfig.json | 9 -
demo/vite.config.ts | 24 +
eslint.config.js | 67 +
jest.config.js | 18 -
package-lock.json | 15974 ----------------
package.json | 133 +-
package.tsconfig.json | 22 +
pnpm-lock.yaml | 3498 ++++
pnpm-workspace.yaml | 8 +
src/ContentCache.ts | 13 +-
src/DirectedScore.ts | 14 +-
src/Mutations.ts | 11 +-
src/SmartPlayer.test.ts | 44 +-
src/SmartPlayer.ts | 17 +-
src/WebAudioContext.ts | 6 +-
src/XAudioBuffer.ts | 6 +-
src/cli.ts | 164 +-
src/index.ts | 37 +-
src/nodes/SPDestinationNode.ts | 10 +-
src/nodes/SPFileNode.ts | 36 +-
src/nodes/SPGainNode.ts | 18 +-
src/nodes/SPLoopNode.test.ts | 60 +-
src/nodes/SPLoopNode.ts | 25 +-
src/nodes/SPNode.ts | 41 +-
src/nodes/SPNodeFactory.ts | 43 +-
src/nodes/SPStretchNode.test.ts | 28 +-
src/nodes/SPStretchNode.ts | 83 +-
src/params/ScoreAudioParam.ts | 15 +-
src/pio.ts | 2 +-
src/renderers/BaseRenderer.ts | 82 +-
src/renderers/MemoryRenderer.test.ts | 17 +-
src/renderers/MemoryRenderer.ts | 13 +-
src/renderers/ScriptProcessorRenderer.ts | 27 +-
src/test-utils/DumpWave.ts | 13 +-
src/test-utils/ExpectQuantums.ts | 2 +-
src/test-utils/LoadWave.ts | 5 +-
src/test-utils/TestRendererInfo.ts | 2 +-
tsconfig.json | 19 +-
tsdown.config.ts | 16 +
vitest.config.ts | 8 +
83 files changed, 4589 insertions(+), 18723 deletions(-)
delete mode 120000 .eslintignore
delete mode 100644 .eslintrc.js
create mode 100644 .github/workflows/ci.yml
create mode 100644 .github/workflows/pages.yml
create mode 100644 .github/workflows/release.yml
create mode 100644 .husky/pre-commit
create mode 100644 .pinact.yaml
create mode 100644 .prettierrc
delete mode 100644 .prettierrc.js
delete mode 100644 .travis.yml
delete mode 100644 debug-harness/declarations.d.ts
create mode 100644 demo.tsconfig.json
delete mode 100644 demo/.npmrc
rename debug-harness/index.html => demo/debug.html (60%)
rename demo/{src => }/index.html (79%)
create mode 100644 demo/monaco-declarations/.gitkeep
delete mode 100644 demo/nf-grapher.d.ts
delete mode 100644 demo/nf-player.d.ts
delete mode 100644 demo/package-lock.json
create mode 100755 demo/scripts/gen-monaco-declarations.sh
rename debug-harness/index.ts => demo/src/debug.ts (76%)
create mode 100644 demo/src/vite-env.d.ts
delete mode 100644 demo/tsconfig.json
create mode 100644 demo/vite.config.ts
create mode 100644 eslint.config.js
delete mode 100644 jest.config.js
delete mode 100644 package-lock.json
create mode 100644 package.tsconfig.json
create mode 100644 pnpm-lock.yaml
create mode 100644 pnpm-workspace.yaml
create mode 100644 tsdown.config.ts
create mode 100644 vitest.config.ts
diff --git a/.eslintignore b/.eslintignore
deleted file mode 120000
index 3e4e48b..0000000
--- a/.eslintignore
+++ /dev/null
@@ -1 +0,0 @@
-.gitignore
\ No newline at end of file
diff --git a/.eslintrc.js b/.eslintrc.js
deleted file mode 100644
index e3e89d2..0000000
--- a/.eslintrc.js
+++ /dev/null
@@ -1,48 +0,0 @@
-const copyrightTemplate = `/*
- * Copyright (c) 2018-Present, Spotify AB.
- *
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-`;
-
-module.exports = {
- extends: [
- //"plugin:@typescript-eslint/recommended",
- 'prettier',
- 'prettier/@typescript-eslint'
- ],
- parser: '@typescript-eslint/parser',
- plugins: ['@typescript-eslint', 'notice'],
- parserOptions: {
- ecmaVersion: 2018,
- sourceType: 'module',
- ecmaFeatures: {
- jsx: true
- }
- },
- rules: {
- 'notice/notice': [
- 'error',
- {
- template: copyrightTemplate,
- onNonMatchingHeader: 'replace'
- }
- ]
- }
-};
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
new file mode 100644
index 0000000..9792a90
--- /dev/null
+++ b/.github/workflows/ci.yml
@@ -0,0 +1,35 @@
+name: ci
+
+on:
+ push:
+ branches: [main]
+ pull_request:
+
+permissions:
+ contents: read
+
+concurrency:
+ group: ci-${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: true
+
+jobs:
+ build:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
+ with:
+ persist-credentials: false
+ - uses: pnpm/action-setup@0e279bb959325dab635dd2c09392533439d90093 # v6.0.8
+ - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
+ with:
+ node-version: 22
+ cache: pnpm
+ - run: pnpm install --frozen-lockfile
+ - run: pnpm typecheck
+ - run: pnpm lint
+ - run: pnpm test
+ - run: pnpm build
+ - run: pnpm validate
+ - name: Build demo
+ working-directory: demo
+ run: pnpm build
diff --git a/.github/workflows/pages.yml b/.github/workflows/pages.yml
new file mode 100644
index 0000000..e60b083
--- /dev/null
+++ b/.github/workflows/pages.yml
@@ -0,0 +1,48 @@
+name: pages
+
+on:
+ push:
+ branches: [main]
+ workflow_dispatch:
+
+permissions:
+ contents: read
+
+concurrency:
+ group: pages
+ cancel-in-progress: false
+
+jobs:
+ build:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
+ with:
+ persist-credentials: false
+ - uses: pnpm/action-setup@0e279bb959325dab635dd2c09392533439d90093 # v6.0.8
+ - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
+ with:
+ node-version: 22
+ cache: pnpm
+ - run: pnpm install --frozen-lockfile
+ - run: pnpm build
+ - name: Build demo
+ working-directory: demo
+ run: pnpm build
+ - uses: actions/configure-pages@45bfe0192ca1faeb007ade9deae92b16b8254a0d # v6.0.0
+ - uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0
+ with:
+ path: demo/dist
+
+ deploy:
+ needs: build
+ runs-on: ubuntu-latest
+ permissions:
+ pages: write
+ id-token: write
+ environment:
+ name: github-pages
+ url: ${{ steps.deployment.outputs.page_url }}
+ steps:
+ - id: deployment
+ uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 # v5.0.0
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
new file mode 100644
index 0000000..b040ff0
--- /dev/null
+++ b/.github/workflows/release.yml
@@ -0,0 +1,34 @@
+name: release
+
+on:
+ release:
+ types: [published]
+
+permissions:
+ contents: read
+
+jobs:
+ publish:
+ runs-on: ubuntu-latest
+ environment: npm
+ permissions:
+ contents: read
+ id-token: write # npm provenance
+ steps:
+ - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
+ with:
+ persist-credentials: false
+ - uses: pnpm/action-setup@0e279bb959325dab635dd2c09392533439d90093 # v6.0.8
+ - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
+ with:
+ node-version: 22
+ cache: pnpm
+ registry-url: https://registry.npmjs.org
+ - run: pnpm install --frozen-lockfile
+ - run: pnpm typecheck
+ - run: pnpm test
+ - run: pnpm build
+ - run: pnpm validate
+ - run: pnpm publish --provenance --access public --no-git-checks
+ env:
+ NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
diff --git a/.gitignore b/.gitignore
index e6d416e..e050d08 100644
--- a/.gitignore
+++ b/.gitignore
@@ -9,3 +9,6 @@ dist-debug
.cache-demo
demo/.cache
coverage
+*.tgz
+demo/monaco-declarations/*.d.ts
+test-results
diff --git a/.husky/pre-commit b/.husky/pre-commit
new file mode 100644
index 0000000..5ee7abd
--- /dev/null
+++ b/.husky/pre-commit
@@ -0,0 +1 @@
+pnpm exec lint-staged
diff --git a/.pinact.yaml b/.pinact.yaml
new file mode 100644
index 0000000..a57366d
--- /dev/null
+++ b/.pinact.yaml
@@ -0,0 +1,5 @@
+# yaml-language-server: $schema=https://raw.githubusercontent.com/suzuki-shunsuke/pinact/refs/heads/main/json-schema/pinact.json
+# pinact - https://github.com/suzuki-shunsuke/pinact
+version: 3
+min_age:
+ value: 7
diff --git a/.prettierrc b/.prettierrc
new file mode 100644
index 0000000..544138b
--- /dev/null
+++ b/.prettierrc
@@ -0,0 +1,3 @@
+{
+ "singleQuote": true
+}
diff --git a/.prettierrc.js b/.prettierrc.js
deleted file mode 100644
index bdf6f9a..0000000
--- a/.prettierrc.js
+++ /dev/null
@@ -1,3 +0,0 @@
-module.exports = {
- singleQuote: true
-};
\ No newline at end of file
diff --git a/.travis.yml b/.travis.yml
deleted file mode 100644
index 1355964..0000000
--- a/.travis.yml
+++ /dev/null
@@ -1,28 +0,0 @@
-language: node_js
-before_install:
-- npm i -g npm@6.8
-cache: npm
-node_js:
-- '10'
-script:
-- npm run setup:ci
-- npm run build
-- npm test -- --coverage
-- npm run predeploy:demo
-deploy:
- - provider: npm
- email: kibysayshi@gmail.com
- skip_cleanup: true
- api_key:
- secure: LFF+TBDO2lguN5rpciP09qUKWIoVVWA2arapTtX+zGMZHBa7QmDV+iBDZSLkf+5iJAgrgXsehIazXyQ7HKDad59y5kjJBOtQOqcSkENn1RTx10FHGvH/lrsO6FxLa5JD0r2cd9KdUjz2EC+4AlgrJo8wr6SKA2/cNOZ2gMVV/6cZVS/sPWfDx9Y1EDQwWlT+74G/vj4FFI+cuHQ2t28aywguaYdMQXPlORo0hXOde4JysewvO2mXcP9viMLg2qckEOeNo0ONDoQtJc4ZDJo7AmOqKmbf14sUQU04ejaw4RLveTe+ebkLYFKC72ABR0RN/VJIlUR78MZXTpJ9tM9A3iLRz1J4ca++3HQMcHQKOG+4P6lSk3bjyUg2pqrYLeUVzAoDIBABJUy0rbhiDMluKiPizO+Y9MmBf57d68+Ks+7ptDuVdYu6J01oyep0D2Mx25IlpgVOORMY05K1CbbWKNAdL8zn54SifqbCDVfDRgrMD0+iQC2D8gKMtOhap3OwtZWOEysUf5wwDz4cEzaeDcL5iOPwxKc6CpjyhdchJDxWozZTA+2wtSAUoddQ4c/iQM1FFQYQ5IugdVOA4/f66aWGftT0CzImT4jC1EHFF6QqAC5R5NAmpt6WaHDt3T/kmSIwXpDxnVq80nzK4t6k1VYjjQhum+IYMq1bx3g6DOM=
- on:
- tags: true
- repo: spotify/NFPlayerJS
- branch: main
- - provider: pages
- github-token: $GITHUB_TOKEN
- skip_cleanup: true
- keep-history: true
- local-dir: demo/dist/
- on:
- branch: main
diff --git a/README.md b/README.md
index ef3ef60..5fcc407 100644
--- a/README.md
+++ b/README.md
@@ -4,17 +4,15 @@
[](LICENSE)
-[](https://slackin.spotify.com)
-[](http://clayallsopp.github.io/readme-score?url=https://github.com/spotify/NFPlayerJS)
A JavaScript/TypeScript audio engine for the Web and Server capable of multitrack time stretching, pitch shifting, declarative effects, faster than realtime processing, and more!
-Developed at Spotify 2017-2018, Discontinued and handed over to new maintainers January 2023
+Developed at Spotify 2017-2018, Discontinued and handed over to new maintainers January 2023
# Getting Started (Browser) 🚀
-1. Install the player: `npm install --save nf-player`
-2. Describe your audio experience using [NFGrapher][nfgrapher] `npm install --save nf-grapher`, or use a prebuilt [JSON Score](./fixtures).
+1. Install the player: `pnpm add nf-player`
+2. Describe your audio experience using [NFGrapher][nfgrapher] (`pnpm add nf-grapher`), or use a prebuilt [JSON Score](./fixtures).
3. Listen to it!
```js
@@ -22,7 +20,7 @@ Developed at Spotify 2017-2018, Discontinued and handed over to new maintainers
import { SmartPlayer, TimeInstant } from 'nf-player';
import * as ScoreJSON from './your-score.json';
-(async function() {
+(async function () {
// Create player. By default it uses Web Audio to insert audio data into
// the current audio device.
const p = new SmartPlayer();
@@ -47,7 +45,7 @@ There are also in-progress [API Docs][api docs].
A [CLI](./src/cli.ts) also ships with this package!
```sh
-$ npx nf-player save --duration 120 --input-file ./fixtures/roxanne-30s-preview-shifted-infinite.json --output-file ./roxanne.wav
+$ pnpm dlx nf-player save --duration 120 --input-file ./fixtures/roxanne-30s-preview-shifted-infinite.json --output-file ./roxanne.wav
```
The above command will load the Score JSON, download the audio files, and render 120 seconds of audio to a file called `tng.wav`. This should happen in about 5 seconds of realtime, depending on your computer and internet connection.
@@ -117,42 +115,46 @@ See the [Playground][playground]!
# Development 🏗
-Clone this repo, then:
+Requires Node ≥20 and [pnpm](https://pnpm.io/).
```sh
-$ npm install
+$ pnpm install # installs the package + the demo workspace
+$ pnpm build # build the library (tsdown → dist/, ESM + CJS + .d.ts)
+$ pnpm test # vitest
+$ pnpm typecheck # tsc -b (whole solution)
+$ pnpm lint
```
-To build the library and start the development environment:
+To run the demo / playground locally:
```sh
-$ npm start
+$ pnpm --filter ./demo dev
```
-To build and publish the demo to [gh-pages](playground) manually, run:
+The demo also exposes a cut-down debug entry at `demo/debug.html` (source: `demo/src/debug.ts`) for poking at single Scores or scripts.
-```sh
-$ npm run deploy:demo:manual
-```
+# Deployment / Publishing / Release 🚢
-Otherwise the demo is actually built and deployed on each push to main.
+### Publishing:
-There is also a more cut-down [debug environment](./debug-harness/index.ts) useful for debugging / developing single Scores or scripts:
+1. Bump the version: `pnpm version `
+2. push, then cut a GitHub Release. Publishing occurs via [`release.yml`](./.github/workflows/release.yml).
-```sh
-$ npm run debug-harness
-```
+### Demo Deployment:
-# Deployment / Publishing / Release 🚢
+- The demo is deployed to GitHub Pages automatically by `pages.yml` on each push to `main`.
-### Publishing:
+### CI workflow actions (SHA-pinned):
-- `npm version [major|minor|patch]`, then PR.
-- TravisCI will attempt to publish any tagged commit.
+Third-party GitHub Actions in `.github/workflows/*.yml` are pinned to full commit SHAs for safety. To bump them, use [pinact](https://github.com/suzuki-shunsuke/pinact):
-### Demo Deployment:
+```sh
+$ brew install suzuki-shunsuke/pinact/pinact
+$ pinact run --update # resolves each tag to its latest SHA, rewrites in place
+$ pinact run --verify # verify SHA ↔ comment match + min-age policy
+```
-- The demo is deployed automatically on main builds using the TravisCI gh-pages provider.
+Project policy lives in [`.pinact.yaml`](./.pinact.yaml).
# Contributing 💖⌨️
diff --git a/debug-harness/declarations.d.ts b/debug-harness/declarations.d.ts
deleted file mode 100644
index edcdf47..0000000
--- a/debug-harness/declarations.d.ts
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * Copyright (c) 2018-Present, Spotify AB.
- *
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-declare module '*.wav';
-declare module '*.mp3';
diff --git a/demo.tsconfig.json b/demo.tsconfig.json
new file mode 100644
index 0000000..43f39d6
--- /dev/null
+++ b/demo.tsconfig.json
@@ -0,0 +1,19 @@
+{
+ "$schema": "https://json.schemastore.org/tsconfig.json",
+ "compilerOptions": {
+ "composite": true,
+ "noEmit": true,
+ "tsBuildInfoFile": "./node_modules/.cache/tsbuildinfo/demo.tsbuildinfo",
+ "strict": true,
+ "target": "ES2022",
+ "lib": ["ES2022", "DOM", "DOM.Iterable"],
+ "module": "preserve",
+ "customConditions": ["source"],
+ "jsx": "react-jsx",
+ "esModuleInterop": true,
+ "resolveJsonModule": true,
+ "skipLibCheck": true,
+ "forceConsistentCasingInFileNames": true
+ },
+ "include": ["demo/src/**/*"]
+}
diff --git a/demo/.npmrc b/demo/.npmrc
deleted file mode 100644
index 38f11c6..0000000
--- a/demo/.npmrc
+++ /dev/null
@@ -1 +0,0 @@
-registry=https://registry.npmjs.org
diff --git a/debug-harness/index.html b/demo/debug.html
similarity index 60%
rename from debug-harness/index.html
rename to demo/debug.html
index 1eff22d..3594ebb 100644
--- a/debug-harness/index.html
+++ b/demo/debug.html
@@ -1,14 +1,12 @@
-
+
NF Debug Harness
-
-
-
+
-
\ No newline at end of file
+