Skip to content

Releases: Qix-/scaly

1.0.1

22 Aug 12:10
Compare
Choose a tag to compare

Patch Release 1.0.1

This is a non-changing release that updates the CI workflows and auto-formats the code.

  • 7629402 Create FUNDING.yml
  • 44d33f1 Update FUNDING.yml
  • ec119c2 ci: move to prettier and add CI workflows

1.0.0

02 Sep 02:03
Compare
Choose a tag to compare

Major Release 1.0.0

This is the first major release of Scaly, which has been used in production in moderate workloads for the better part of a year now.

Changes from latest scaly@<1 version

  • Adds Typescript type definitions (#1)
  • Brings XO up to date

Using Typescript

import scaly, {ScalyResult} from 'scaly';
// or
import {scaly, ScalyResult} from 'scaly';

const layer1 = {
    async *getUsername(id: number): ScalyResult<string> {
        return "Junon";
    }
};

const layer2 = {
    async *getUsername(id: number): ScalyResult<string> {
        console.log('CACHE: user', id, 'has username', yield);
    }
};

const api = scaly(layer2, layer1);
api.getUsername(0).then(result => console.log('RESULT:', result));

Migrating from scaly@<1

  • Layers are now passed as splats, not as arrays. This was done to facilitate Typescript definitions.
-scaly([layer1, layer2, layer3])
+scaly(layer1, layer2, layer3)

Thank you to @dylan1p for the feedback and testing throughout the last year, and @rainandwind0 for hallway testing the concepts and ideas and interface alongside me.