From cda60c7a50c5b37c6f0bd888b48ac86a899dd3f0 Mon Sep 17 00:00:00 2001 From: Reinder Nijhoff Date: Mon, 18 Mar 2024 20:43:00 +0100 Subject: [PATCH] Cleanup --- example/counter.js | 9 --------- src/lib/{ditty-worker.txt => ditty-worker.js} | 0 src/lib/dittytoy.js | 2 +- 3 files changed, 1 insertion(+), 10 deletions(-) delete mode 100644 example/counter.js rename src/lib/{ditty-worker.txt => ditty-worker.js} (100%) diff --git a/example/counter.js b/example/counter.js deleted file mode 100644 index 881e2d7..0000000 --- a/example/counter.js +++ /dev/null @@ -1,9 +0,0 @@ -export function setupCounter(element) { - let counter = 0 - const setCounter = (count) => { - counter = count - element.innerHTML = `count is ${counter}` - } - element.addEventListener('click', () => setCounter(counter + 1)) - setCounter(0) -} diff --git a/src/lib/ditty-worker.txt b/src/lib/ditty-worker.js similarity index 100% rename from src/lib/ditty-worker.txt rename to src/lib/ditty-worker.js diff --git a/src/lib/dittytoy.js b/src/lib/dittytoy.js index 5797101..6e6a79c 100644 --- a/src/lib/dittytoy.js +++ b/src/lib/dittytoy.js @@ -1,6 +1,6 @@ "use strict"; -import workerCode from './ditty-worker.txt?raw'; +import workerCode from './ditty-worker.js?raw'; import workletCodeURL from './ditty-worklet.js?url'; export const LOOP_OPERATOR_SYNTH = 0;