MCPcopy Create free account
hub / github.com/processing/p5.js / urlToStrandsCallback

Function urlToStrandsCallback

src/webgl/material.js:13–16  ·  view source on GitHub ↗
(url)

Source from the content-addressed store, hash-verified

11import { Color } from "../color/p5.Color";
12
13async function urlToStrandsCallback(url) {
14 const src = await fetch(url).then((res) => res.text());
15 return new Function(src);
16}
17
18function withGlobalStrands(p5, cb) {
19 const prevGlobalStrands = p5._runStrandsInGlobalMode;

Callers 1

materialFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected