Skip to content

@glandjs/core@1.0.3-beta · @glandjs/core@1.0.3-beta · @glandjs/common@1.0.3-beta

Changelog — @glandjs/core & common

Release history for @glandjs/core & common, mirrored from the repository.

Release notes for the Gland packages in this repository. Each package also has its own CHANGELOG.md, generated by changesets.

Package Version
@glandjs/core 2.0.0
@glandjs/common 1.1.0

2.0.0 — @glandjs/core, 1.1.0 — @glandjs/common

Section titled “2.0.0 — @glandjs/core, 1.1.0 — @glandjs/common”

The beta hardened the core. The headline change is that emitDecoratorMetadata is now a stated requirement rather than an accident, because without it the container could not know what to inject.

Migration

  1. Add @Injectable() to any class the container constructs that has constructor parameters and no other Gland decorator. TypeScript only emits design:paramtypes for decorated classes.

  2. GlandFactory.create() now returns { app, shutdown }:

    // before
    const app = await GlandFactory.create(AppModule);
    // after
    const { app, shutdown } = await GlandFactory.create(AppModule);
  3. Module the injector class is now ModuleRef, imported from @glandjs/core. The name @Module() stays with the decorator in @glandjs/common.

  4. An unknown channel event now throws UnknownEventError, listing the events that exist. If you relied on ctx.call() returning undefined for a misspelled name, catch it or check the name.

  5. DynamicModule.exports and DynamicModule.global were removed. They were declared but never implemented, so nothing that worked stops working.

See the package changelogs for the full list, and dependency injection for the reasoning behind each change.

  • Initial public beta of the two-package core.