From 0595aaf3c806dc42b591f9bad0770ce6f26537e9 Mon Sep 17 00:00:00 2001 From: David Konsumer Date: Tue, 5 Nov 2024 18:36:56 -0800 Subject: [PATCH] subverting pedantic tooling --- src/dsp.ts | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/dsp.ts b/src/dsp.ts index 61c3af9..234e302 100644 --- a/src/dsp.ts +++ b/src/dsp.ts @@ -54,11 +54,14 @@ export const dsp = (options: DspOptions = {}) => { let dsp: AudioWorkletNode; - audioCtx.audioWorklet.addModule(workletUrl).then(() => { - dsp = new AudioWorkletNode(audioCtx, 'zenfs-dsp'); - dsp.connect(audioCtx.destination); - dsp.port?.postMessage(audioBuffer); - }).catch(e => {}); + audioCtx.audioWorklet + .addModule(workletUrl) + .then(() => { + dsp = new AudioWorkletNode(audioCtx, 'zenfs-dsp'); + dsp.connect(audioCtx.destination); + dsp.port?.postMessage(audioBuffer); + }) + .catch(e => {}); // add a click-handler to resume (due to web security) https://goo.gl/7K7WLu document.addEventListener('click', () => {