Releases: JuliaJSXGraph/JSXGraph.jl
v0.5.3
JSXGraph v0.5.3
Added
@jsfnow transpiles Julia property-access expressions (obj.prop) and method-call syntax (obj.prop()) to their JS equivalents. Combined with the v0.5.2 element-ref capture, this enables the classic JSXGraph wiki idiom of using a draggable point's live coordinate inside a function expression, e.g.@jsf x -> α.X()^xwhereαis apoint.line(c::Real, b::Real, a::Real; kwargs...)— three-argument constructor accepting JSXGraph's homogeneous-coordinate line formc + b·x + a·y = 0. Convenient as the boundary parent of aninequalityelement.- New documentation page Wiki Examples (
docs/src/wiki_examples.md) reproducing the first batch of slider-driven examples from the JSXGraph upstream wiki: draggable-exponential function (A.Y()^(x/A.X())with point on the curve by construction), Lituus polar spiral withkslider, P-Norm unit ball, slider-driven quartic polynomial, Taylor approximations ofsinwith truncation-order slider via rawJSFunction, three-slider (n, start, end) Riemann sum, and linear half-plane inequalities. Tracks the wishlist from #6.
Changed
_call_to_jsnow routes non-Symbolcall heads (e.g. anExpr(:.)forpoint.X()) throughjulia_to_js, fixing syntactically-invalid JS that was previously emitted as a Julia-stylerepr(::Expr). BareSymbolcall heads (math functions,named_jsfreferences, JS builtins) keep their existing fast path.
v0.5.2
JSXGraph v0.5.2
Fixed
@jsfnow resolves free Julia symbols that referenceJSXElementvalues (typically sliders) to their JS variable. Previously@jsf x -> s * x^2emitted an undefinedsidentifier in the rendered JavaScript and the dependent element silently failed to render. Slider references auto-append.Value(), so the documenteds * x^2idiom from the tutorial works as-is.
Added
- Free symbols in
@jsflambdas that resolve toReal,Bool, orAbstractStringJulia bindings are inlined as JS literals (e.g.@jsf x -> x + kwithk = 3.14emitsx + 3.14). JSFunctiongains an internalrefs::Dict{String,Any}field that records captured Julia bindings for placeholder substitution at render time. Backward-compatible constructors are preserved.
Changed
- The JS
val,valx,valyhelpers inPREAMBLEare now idempotent on numbers (typeof x === "number" ? x : x.Value()), makingval(s)safe to use alongside the new auto-deref.
v0.5.1
JSXGraph v0.5.1
Fixed
scatter(x, y)andplot(table, :x, :y)(Tables.jl extension) no longer produce an invalid(NaN, NaN, NaN, NaN)bounding box when the data containsNaNorInf. Non-finite values are filtered before computing the auto-padded axis range, with a safe(-1.0, 1.0)fallback when no finite values remain. This unblocks the classic JSXGraph scatter-via-curve idiom ([x, x, NaN, ...]) when using the auto-axis path.
Closed issues:
v0.5.0
JSXGraph v0.5.0
Breaking changes
v0.5.0 is a complete rewrite of JSXGraph.jl. The package has been re-architected from the ground up and the public API differs substantially from the 0.1.x series — there is no API compatibility with previous versions. Users of 0.1.x should treat this as a new package and consult the updated documentation.
New features
Pluto integration
- Pluto
@bindsupport viabindable=trueonboard(...). The bound state exposes draggable points (2D + 3D) and sliders by name, withpoints_xy/points_xyzhelpers for spline / regression / array workflows (#12). - Optional weak dependency on
AbstractPlutoDingetjes(loaded automatically by Pluto) routes seed coordinates throughpublished_to_js; outside Pluto a JSON-inline fallback keeps the feature working with zero new dependencies.
3D
View3Dcontainer with do-block syntax andview3dconstructor.- 3D element constructors:
point3d,line3d,curve3d,functiongraph3d,parametricsurface3d,vectorfield3d,sphere3d,circle3d,polygon3d,plane3d,intersectionline3d,intersectioncircle3d,text3d,mesh3d,polyhedron3d. - 3D theming (
THEME_DARK,THEME_PUBLICATION) and 3D attribute aliases (surfacecolor,wireframecolor,meshcolor, …). - 3D gallery with 28 interactive examples.
Integrations & ergonomics
- Observables.jl:
Observablevalues as parents/attributes are automatically unwrapped at render time. - MathJS:
enable_mathjs!()/disable_mathjs!()to extend@jsfwithgamma,erf,factorial, and 20+ additional math functions via MathJS CDN. - Gallery documentation page with 37 categorized examples (slider-driven interactive demos).
Fixes
- 3D gallery now uses
axis=falseon the parent board so only theView3Daxes are drawn. functiongraph3dinherits x/y ranges from parentView3Dwhen not explicitly provided (fixesSurface3D.updateWireframecrash).- CDN fragment loader detects RequireJS via
requirejsglobal instead of failing on Pluto's customrequire. - String arguments to
functiongraph,slopefield,vectorfield,implicitcurveare wrapped as JS function expressions instead of JSON-quoted JessieCode strings. slopefield/vectorfieldnow pass requiredxData/yDatagrids (fixes empty slope fields).riemannsumextracts the underlyingJSFunctionfromJSXElementparents.
Closed issues:
v0.1.7
Changes
- Replaced Travis CI with GitHub Actions and Codecov
- Updated authors to JuliaJSXGraph maintainers
- Added MAINTAINERS file
- Switched .gitignore to gitallow approach
- Updated repo URL in General registry to JuliaJSXGraph org
This is the last patch release before upcoming breaking changes.
v0.1.6
JSXGraph v0.1.6
This release has been identified as a backport.
Automated changelogs for backports tend to be wildly incorrect.
Therefore, the list of issues and pull requests is hidden.
v0.1.5
JSXGraph v0.1.5
This release has been identified as a backport.
Automated changelogs for backports tend to be wildly incorrect.
Therefore, the list of issues and pull requests is hidden.
v0.1.4
JSXGraph v0.1.4
This release has been identified as a backport.
Automated changelogs for backports tend to be wildly incorrect.
Therefore, the list of issues and pull requests is hidden.
JSXGraph 1.12.2 Assets
JSXGraph JavaScript library v1.12.2 artifact