Skip to content

chore: release - #425

Merged
linked-fw-release[bot] merged 1 commit into
mainfrom
changeset-release/main
Nov 24, 2026
Merged

linked-fw-release[bot] merged 1 commit into
mainfrom
changeset-release/main

Conversation

@linked-fw-release

Copy link
Copy Markdown
Contributor

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and publish to npm yourself or setup this action to publish automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated.

Releases

@_linked/core@3.0.0

Major Changes

  • #424 3a64295 Thanks @flyon! - Prefixes are the app's, and ontologies register with one call per package.

    • registerOntologies(ontologies, moduleUrl) replaces linkedOntology, which is removed. A package's src/ontologies/index.ts imports its terms modules (only {id} literals) and registers them all: registerOntologies([{name, namespace, terms, data?, suggestedPrefix?}], import.meta.url), data relative to moduleUrl. It registers no prefix. OntologyRegistration has namespace and suggestedPrefix instead of ns; suggestedPrefixes() lists {packageName, name, namespace, prefix}.
    • registerInstalledOntologies imports <pkg>/ontologies/index instead of ontologies/*.register modules.
    • No ontology registers a prefix, core's own included (rdf, rdfs, owl, xsd, shacl, sd, prov, core; the deprecated linked_core label is gone). An app loads its map with Prefix.load(map) (replaces the map in use; PrefixMap is Record<prefix, namespace>); Prefix.toMap() returns it.
    • An unknown prefix throws UnknownPrefixError (naming the prefix and the value) wherever a prefixed name is expanded: Prefix.toFull, query subjects (.for('ex:a')), update().for and delete ids (which were never expanded before), and property path steps (which were written as <p:x> with a warning). A string with :// or the scheme http, https, urn, mailto, did, file or data is a full IRI (Prefix.isFullIri).
    • Expansion and compaction take an optional explicit map, for code acting for another app: Prefix.toFull, toPrefixed, toPrefixedIfPossible, getFullURI, getPrefix, findMatch, resolveUriOrThrow, resolveNodeId, pathRefIri, expandPrefixedName.
    • Removed: Prefix.toFullIfPossible, resolvePrefixedUri, expandRegisteredPrefixedName (now expandPrefixedName, which throws), linked-core.register. linked-core.ts exports coreOntology only (no ns, _self, dataFiles, loadData).

Minor Changes

  • #424 7e2ca24 Thanks @flyon! - linkedOntology(terms, ns, name, loadData?, dataFiles?): the third argument is the ontology's name within its package (unique in the package, need not equal the module's file name), not a prefix. OntologyRegistration.prefix is now .name, and the registry is keyed by package and name. A registration an older copy of core wrote (a prefix, no name) is skipped with one warning. linkedOntology still registers the name as a prefix with Prefix.

Patch Changes

  • #424 50ef261 Thanks @flyon! - Comments state the IRI and routing rules inline.

  • #424 6fb74a6 Thanks @flyon! - @_linked/core/ontology/loadOntologyFiles: its documentation describes how registerOntologies loads an ontology's data files.

  • #424 7eac669 Thanks @flyon! - The ontology is declared in package.json "linkedOntologies" and its data states its suggested prefix and namespace (vann:preferredNamespacePrefix, vann:preferredNamespaceUri); the module stays hand-written ("generated": false). No import path or export changes.

@linked-fw-release
linked-fw-release Bot merged commit f84a22a into main Nov 24, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants