mirror of
https://github.com/eliasstepanik/strudel-docker.git
synced 2026-01-11 21:58:31 +00:00
prettier code formatting
This commit is contained in:
parent
a58ac967a6
commit
0a280e9399
@ -1,14 +1,13 @@
|
||||
import { getDrawContext } from '@strudel.cycles/core';
|
||||
|
||||
let options = ""
|
||||
let options = '';
|
||||
|
||||
export async function initHydra(config) {
|
||||
|
||||
//load and init hydra
|
||||
if (!document.getElementById('hydra-canvas')) {
|
||||
const { canvas: testCanvas } = getDrawContext();
|
||||
await import('https://unpkg.com/hydra-synth');
|
||||
h = new Hydra({detectAudio: config?.audio });
|
||||
h = new Hydra({ detectAudio: config?.audio });
|
||||
h.canvas.id = 'hydra-canvas';
|
||||
h.canvas.style.position = 'absolute';
|
||||
h.canvas.style.top = '0px';
|
||||
@ -19,11 +18,10 @@ export async function initHydra(config) {
|
||||
if (options != JSON.stringify(config)) {
|
||||
options = JSON.stringify(config);
|
||||
|
||||
new Hydra(
|
||||
{
|
||||
canvas: document.getElementById('hydra-canvas'),
|
||||
detectAudio: config?.audio
|
||||
})
|
||||
new Hydra({
|
||||
canvas: document.getElementById('hydra-canvas'),
|
||||
detectAudio: config?.audio,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user