Repository navigation
v0.12.0
Minor changes
-
603551e: JavaScript API: before 1.0, the npm packages keep only the API they document, so that nothing kgdiff uses internally becomes a promise. Each entry point now has an API report (
packages/<name>/api/*.api.md) that CI compares with the built declarations. Pages that use the viewer's elements through their attributes, properties, methods and events, and code that uses the other packages as documented, need no change. Guide: Migrating to 0.12.@kgdiff/viewer/elements/*: the element classes' declarations no longer show the members a subclass would override (build,name,shadow,context,upgradedProperties, and the hooks of<kgdiff-root>), norKgdiffStage'sview. Subclassing the element classes is not covered by semantic versioning: an element's public interface is whatcustom-elements.jsonlists. Extend an element by composition (slots,addLayer,registerObstacle, events).@kgdiff/viewer/elements/stageno longer exportsSTAGE_REGIONS: use theStageRegionvalues ('dock','transport','legend','zoom','minimap'). It exportsContext, the type ofstageContext.@kgdiff/compute/layoutno longer exportslayoutModule: callinit()and the entry point's functions.@kgdiff/core/computedis an internal entry point of@kgdiff/computeof the same version, not covered by semantic versioning.@kgdiff/g6exportsElementKind, the type ofKgdiffDatumData.kgdiff.@kgdiff/scene:shape2ofEdgeVisualandGlyphVisualis documented as experimental, likeshape1.
@kgdiff/core·@kgdiff/scene·@kgdiff/viewer·@kgdiff/g6·@kgdiff/compute -
eb7d948: Rust crates: the public Rust API makes room for the additions planned after 1.0, so that none of them needs a major release. The JavaScript API changes too, in a separate entry (it keeps only what is documented); the CLI, the document formats and every output byte are those of 0.11, so for the command line the upgrade is the version number. Guide: Migrating to 0.12; what each version promises from now on: Versioning.
- Enums that will grow are
#[non_exhaustive](error, issue and warning codes, formats, locales, strategies, facets, delta ops): amatchon them needs a_arm.ChangeStatus,HunkKind,ReplayPhase,SuggestionReason,Endandjs::Valuestay exhaustive. - Options, inputs and results are
#[non_exhaustive]: build them fromDefault::default()or a constructor and set the fields (let mut options = DiffOptions::default(); options.edge_identity = …;). New constructors:ReportInfo::new,ReportSide::new,ViewerBundles::new,MarkdownOptions::new,TextContext::new. - The internals kgdiff's crates share are hidden from the documentation and not covered by semantic versioning:
kgdiff_core::jsapart fromValue,Object,JsStr,json,IndexMapandIndexSet;kgdiff_core::{canonical, text, util};kgdiff_report::{locale, model, width}; every module ofkgdiffapart fromcli,io,systemandtesting. kgdiff_core::js::BuildHasher(the hasher of the publicIndexMapandIndexSet) is kgdiff's own type instead offoldhash::fast::RandomState, so that a foldhash upgrade cannot change the public types.- The
kgdiffcrate's embedding interface:CliIo::viewer_bundlereturnsViewerMissinginstead of the internalFailure;FileStat(FileStat::new),ViewerBundleandSystemIo(SystemIo::default()) are#[non_exhaustive]. - CI checks the Rust API against the last release with
cargo-semver-checks.
@kgdiff/core - Enums that will grow are
Patch changes
-
21f269c: Rust crates only: the public API of
kgdiff-core,kgdiff-formats,kgdiff-layout,kgdiff-reportandkgdiffis documented on docs.rs: every public type, field, variant and function has a description, functions that returnResultsay what they fail with, and the crate pages and READMEs describe what each crate provides, with an example that runs as a test.#![warn(missing_docs)]keeps it that way. No type, signature or behavior changes.@kgdiff/core
Every package is at 0.12.0: @kgdiff/cli · @kgdiff/core · @kgdiff/formats · @kgdiff/layout · @kgdiff/scene · @kgdiff/renderer · @kgdiff/viewer · @kgdiff/g6 · @kgdiff/compute.
GitHub Action: uses: iiwish/kgdiff@v0.12.0.