Published
Edited
Jun 4, 2021
Insert cell
Insert cell
Insert cell
p5((sketch) => {
sketch.setup = () => {
sketch.createCanvas(400, 400);
sketch.background(0);
sketch.stroke(255, 255, 255);
};

sketch.draw = () => {
sketch.strokeWeight(2);
sketch.line(sketch.pmouseX, sketch.pmouseY, sketch.mouseX, sketch.mouseY);
};
})
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more