hi I'm trying to get this code to work:
https://github.com/MrToph/metaballs-js/tree/master/packages/metaballs-js
i created a boilerplate html5 file with a link to script.js
inside the JS file Have the exact code
import initMetaballs from "metaballs-js";
const options = {
numMetaballs: 100,
minRadius: 3,
maxRadius: 7.5,
speed: 10.0,
color: '#ff0024',
backgroundColor: '#121212',
useDevicePixelRatio: true
}
const cssSelector = '#canvasId'
initMetaballs(cssSelector, options)
But when I try run this using VScode I get this error in Chrome:
SyntaxError: Unexpected identifier 'initMetaballs'. import call expects one or two arguments.
GitHub
Monorepo for all the official metaballs-js libraries. - MrToph/metaballs-js