Published
Edited
Jun 29, 2022
Importers
2 stars
Insert cell
Insert cell
Insert cell
Insert cell
mutable innerHeight = observeWindowProperty("innerHeight")
Insert cell
mutable outerHeight = observeWindowProperty("outerHeight")
Insert cell
mutable innerWidth = observeWindowProperty("innerWidth")
Insert cell
mutable outerWidth = observeWindowProperty("outerWidth")
Insert cell
observeWindowProperty = _.curry(observeProperty)(window)
Insert cell
observeProperty = (object, property) =>
Generators.observe((notify) => {
let temp;

const interval = setInterval(() => {
if (temp !== object[property]) notify((temp = object[property]));
});

return () => clearInterval(interval);
})

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