Looking for something like GeoGebra†, but usable on the Web, I came across this JavaScript library (which depends on d3.js to draw the SVGs). It’s available for Node on npm‡.<p>What I especially like is the simple, declarative syntax, allowing to draw geometry diagrams in the classic euclidian style, as e.g. in this constructive proof: <a href="http://euclid.js.org/parse.html" rel="nofollow">http://euclid.js.org/parse.html</a><p>There are many charting libraries, all focussing on data visualizations and statistical (or data-driven) plots. But a comprehensive library to draw abstract geometry seems to be a desideratum still. There remains much to be desired in this one, Euclid.js, too.<p>For example, if one would want to draw a diagram based on a rectangle of a given proportion, then, with Euclid.js, the rectangle must be tediously drawn from Euclidian primitives (point, intersection, line, circle, segment) first, before one can actually start drawing the desired figure from there.<p>Ideally, the drawing library would have built-in convenience constructs for frequently used geometrical figures such as a square, a root-two rectangle, an isosceles triangle, an equilateral triangle, other regular polygons, methods for bisecting a line segment, trisecting, etc. etc. And it would be really nice, if relevant points would be labeled using a system of choice (ABC or ΑΒΓ), and when significant features of the drawing would be shown (segments of equal length marked, right angles, etc.).<p>† <a href="https://www.geogebra.org/" rel="nofollow">https://www.geogebra.org/</a>
‡ <a href="https://www.npmjs.com/package/euclid" rel="nofollow">https://www.npmjs.com/package/euclid</a>