mirror of
https://github.com/eliasstepanik/strudel-docker.git
synced 2026-01-24 03:58:53 +00:00
hotfix: prebake flag to skip fetch
This commit is contained in:
parent
21b2184750
commit
8244ba7754
@ -1,7 +1,7 @@
|
|||||||
import { Pattern, toMidi } from '@strudel.cycles/core';
|
import { Pattern, toMidi } from '@strudel.cycles/core';
|
||||||
import { samples } from '@strudel.cycles/webaudio';
|
import { samples } from '@strudel.cycles/webaudio';
|
||||||
|
|
||||||
export function prebake() {
|
export function prebake(isMock = false) {
|
||||||
samples(
|
samples(
|
||||||
{
|
{
|
||||||
piano: {
|
piano: {
|
||||||
@ -41,9 +41,11 @@ export function prebake() {
|
|||||||
// License: CC-by http://creativecommons.org/licenses/by/3.0/ Author: Alexander Holm
|
// License: CC-by http://creativecommons.org/licenses/by/3.0/ Author: Alexander Holm
|
||||||
'./piano/',
|
'./piano/',
|
||||||
);
|
);
|
||||||
fetch('EmuSP12.json')
|
if (!isMock) {
|
||||||
.then(res => res.json())
|
fetch('EmuSP12.json')
|
||||||
.then(json => samples(json, './EmuSP12/'));
|
.then((res) => res.json())
|
||||||
|
.then((json) => samples(json, './EmuSP12/'));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const maxPan = toMidi('C8');
|
const maxPan = toMidi('C8');
|
||||||
|
|||||||
@ -123,7 +123,7 @@ const uiHelpersMocked = {
|
|||||||
backgroundImage: id,
|
backgroundImage: id,
|
||||||
};
|
};
|
||||||
|
|
||||||
prebake();
|
prebake(true);
|
||||||
|
|
||||||
// TODO: refactor to evalScope
|
// TODO: refactor to evalScope
|
||||||
extend(
|
extend(
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user