Better DevX for Event Sourcing in TypeScript πŸ§‘β€πŸ’»

Overview

Castore 🦫



Better DevX for Event Sourcing in TypeScript

Castore provides a unified interface for implementing Event Sourcing in TypeScript πŸ¦Έβ€β™‚οΈ .

πŸ€” Why use Castore ?

  • πŸ’¬ Verbosity: Castore classes are designed to increase dryness and provide the optimal developer experience. Event Sourcing is hard, don't make it harder!

  • πŸ“ Strong typings: We love type inference, we know you will to!

  • πŸ„β€β™‚οΈ Interfaces before implementations: Castore provides a standard interface to modelize common event sourcing patterns in TypeScript. But it DOES NOT enforce any particular implementation (storage service, messaging system etc...). You can use Castore in React apps, containers or lambdas, it's up to you! Some common implementations are provided, but you are free to use any implementation you want via custom classes, as long as they follow the required interfaces.

  • πŸ‘ Enforces best practices: Gained from years of usage like using integer versions instead of timestamps, transactions for multi-store events and state-carrying transfer events for projections.

  • πŸ›  Rich suite of helpers: Like mock events builder to help you write tests.

Table of content

Events

The first step in your ✨ Castore journey ✨ is to define your business events! 🦫

Castore lets you easily create the Event Types which will constitute your Event Store. Simply use the EventType class and start defining, once and for all, your events! πŸŽ‰

import { EventType } from "@castore/core"

export const userCreatedEvent = new EventType<
  // Typescript EventType
  'USER_CREATED',
  // Typescript EventDetails
  {
    aggregateId: string;
    version: number;
    type: 'USER_CREATED';
    timestamp: string;
    payload: { name: string; age: number };
  }
>({
  // EventType
  type: 'USER_CREATED',
});

const userRemovedEvent = ...

const eventTypes = [
  userCreatedEvent,
  userRemovedEvent,
];

You can also define your events with JSON Schemas or Zod Events, see @castore/json-schema-event and @castore/zod-event documentations for implementation 🦫

Once you're happy with your set of EventTypes you can move on to step 2: attaching the EventTypes to an actual EventStore! πŸͺ .

Event Store

Welcome in the heart of Castore: the EventStore ❀️
The EventStore class lets you instantiate an object containing all the methods you will need to interact with your event sourcing store. πŸ’ͺ

const userEventStore = new EventStore({
  eventStoreId: 'user-event-store-id',
  eventTypes,
  // πŸ‘‡ See #reducer sub-section
  reducer,
  // πŸ‘‡ See #storage_adapters section
  storageAdapter,
});

Reducer

The reducer needed in the EventStore initialization is the function that will be applied to the sorted array of events in order to build the aggregates βš™οΈ . It works like your usual Redux reducer!

Basically, it consists in a function implementing switch cases for all event types and returning the aggregate updated with your business logic. 🧠

Here is an example reducer for our User Event Store.

export const usersReducer = (
  userAggregate: UserAggregate,
  event: UserEventsDetails,
): UserAggregate => {
  const { version, aggregateId } = event;

  switch (event.type) {
    case 'USER_CREATED': {
      const { name, age } = event.payload;

      return {
        aggregateId,
        version: event.version,
        name,
        age,
        status: 'CREATED',
      };
    }
    case 'USER_REMOVED':
      return {
        ...userAggregate,
        version,
        status: 'REMOVED',
      };
  }
};

Storage Adapter

'Storage Adapter'

You can store your events in many different ways. To specify how to store them (in memory, DynamoDB...) Castore implements Storage Adapters.

Adapters offer an interface between the Event Store class and your storage method πŸ’Ύ .

To be able to use your EventStore, you will need to attach a Storage Adapter πŸ”— .

All the Storage Adapters have the same interface, and you can create your own if you want to implement new storage methods!

So far, castore supports 2 Storage Adapters ✨ :

  • in-memory
  • DynamoDB

Event Store Interface

Now that our Event Store has been instantiated with a reducer and a Storage Adapter, we can start using it to actually populate our database with events and retrieve business data from it 🌈 .

To do that, the Event Store class exposes several methods, including the following two:

  • pushEvent: Takes an object containing event details and puts it in the database. It will throw if the event's version already exists!

  • getAggregate: Returns the output of the reducer applied to the array of all events.

Here is a quick example showing how an application would use these two methods:

const removeUser = async (userId: string) => {
  // get the aggregate for that userId,
  // which is a representation of our user's state
  const { aggregate } = await userEventStore.getAggregate(userId);

  // use the aggregate to check the user status
  if (aggregate.status === 'REMOVED') {
    throw new Error('User already removed');
  }

  // put the USER_REMOVED event in the event store 🦫
  await userEventStore.pushEvent({
    aggregateId: userId,
    version: aggregate.version + 1,
    type: 'USER_REMOVED',
    timestamp: new Date(),
  });
};

Going Further πŸƒβ€β™‚οΈ

We've only covered the basic functionalities of the Event Store!

The Event Store class actually implements other very useful methods πŸ’ͺ

Here is a small recap of these methods:

  • getEvents: Returns the list of all events for a given aggregateId.

  • listAggregateIds: Returns the list of all aggregateIds present in the Event Store.

  • simulateAggregate: Simulates the aggregate you would have obtained with getAggregate at a given date.

Comments
  • Bug in the docs

    Bug in the docs

    I think the documentation has become somewhat inaccurate:

    const userEventStore = new EventStore({
      eventStoreId: 'USERS',
      eventTypes: [
        userCreatedEventType,
        userRemovedEventType,
        ...
      ],
      reducer: usersReducer,
    });
    

    this seems to be written as this now:

    const userEventStore = new EventStore({
      eventStoreId: 'USERS',
      eventStoreEvents: [
        userCreatedEventType,
        userRemovedEventType,
        ...
      ],
      reduce: usersReducer,
    });
    
    opened by neochief 3
  • fix: add sponsor button

    fix: add sponsor button

    Description 🦫

    Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

    Fixes # (issue)

    Type of change πŸ“

    Please delete options that are not relevant.

    • [ ] Bug fix (non-breaking change which fixes an issue)
    • [ ] New feature (non-breaking change which adds functionality)
    • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
    • [ ] This change requires a documentation update

    How Has This Been Tested? πŸ§‘β€πŸ”¬

    Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

    • [ ] Test A
    • [ ] Test B

    Test Configuration: πŸ”§

    • Firmware version:
    • Hardware:
    • Toolchain:
    • SDK:

    Checklist: βœ…

    • [ ] My code follows the style guidelines of this project
    • [ ] I have performed a self-review of my own code
    • [ ] I have commented my code, particularly in hard-to-understand areas
    • [ ] I have made corresponding changes to the documentation
    • [ ] My changes generate no new warnings
    • [ ] I have added tests that prove my fix is effective or that my feature works
    • [ ] New and existing unit tests pass locally with my changes
    • [ ] Any dependent changes have been merged and published in downstream modules
    patch 
    opened by ThomasAribart 0
  • feature: Enable context in commands

    feature: Enable context in commands

    Description 🦫

    Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

    Fixes # (issue)

    Type of change πŸ“

    Please delete options that are not relevant.

    • [ ] Bug fix (non-breaking change which fixes an issue)
    • [ ] New feature (non-breaking change which adds functionality)
    • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
    • [ ] This change requires a documentation update

    How Has This Been Tested? πŸ§‘β€πŸ”¬

    Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

    • [ ] Test A
    • [ ] Test B

    Test Configuration: πŸ”§

    • Firmware version:
    • Hardware:
    • Toolchain:
    • SDK:

    Checklist: βœ…

    • [ ] My code follows the style guidelines of this project
    • [ ] I have performed a self-review of my own code
    • [ ] I have commented my code, particularly in hard-to-understand areas
    • [ ] I have made corresponding changes to the documentation
    • [ ] My changes generate no new warnings
    • [ ] I have added tests that prove my fix is effective or that my feature works
    • [ ] New and existing unit tests pass locally with my changes
    • [ ] Any dependent changes have been merged and published in downstream modules
    minor 
    opened by ThomasAribart 0
  • feature: Remove timestamp from pushEvent input (set it automatically)

    feature: Remove timestamp from pushEvent input (set it automatically)

    Description 🦫

    Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

    Fixes # (issue)

    Type of change πŸ“

    Please delete options that are not relevant.

    • [ ] Bug fix (non-breaking change which fixes an issue)
    • [ ] New feature (non-breaking change which adds functionality)
    • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
    • [ ] This change requires a documentation update

    How Has This Been Tested? πŸ§‘β€πŸ”¬

    Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

    • [ ] Test A
    • [ ] Test B

    Test Configuration: πŸ”§

    • Firmware version:
    • Hardware:
    • Toolchain:
    • SDK:

    Checklist: βœ…

    • [ ] My code follows the style guidelines of this project
    • [ ] I have performed a self-review of my own code
    • [ ] I have commented my code, particularly in hard-to-understand areas
    • [ ] I have made corresponding changes to the documentation
    • [ ] My changes generate no new warnings
    • [ ] I have added tests that prove my fix is effective or that my feature works
    • [ ] New and existing unit tests pass locally with my changes
    • [ ] Any dependent changes have been merged and published in downstream modules
    minor 
    opened by ThomasAribart 0
  • fix: remove lodash from dependencies

    fix: remove lodash from dependencies

    Description 🦫

    Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

    Fixes # (issue)

    Type of change πŸ“

    Please delete options that are not relevant.

    • [ ] Bug fix (non-breaking change which fixes an issue)
    • [ ] New feature (non-breaking change which adds functionality)
    • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
    • [ ] This change requires a documentation update

    How Has This Been Tested? πŸ§‘β€πŸ”¬

    Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

    • [ ] Test A
    • [ ] Test B

    Test Configuration: πŸ”§

    • Firmware version:
    • Hardware:
    • Toolchain:
    • SDK:

    Checklist: βœ…

    • [ ] My code follows the style guidelines of this project
    • [ ] I have performed a self-review of my own code
    • [ ] I have commented my code, particularly in hard-to-understand areas
    • [ ] I have made corresponding changes to the documentation
    • [ ] My changes generate no new warnings
    • [ ] I have added tests that prove my fix is effective or that my feature works
    • [ ] New and existing unit tests pass locally with my changes
    • [ ] Any dependent changes have been merged and published in downstream modules
    patch 
    opened by ThomasAribart 0
  • fix: use redux-event-storage-adapter in demo/visualization

    fix: use redux-event-storage-adapter in demo/visualization

    Description 🦫

    Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

    Fixes # (issue)

    Type of change πŸ“

    Please delete options that are not relevant.

    • [ ] Bug fix (non-breaking change which fixes an issue)
    • [ ] New feature (non-breaking change which adds functionality)
    • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
    • [ ] This change requires a documentation update

    How Has This Been Tested? πŸ§‘β€πŸ”¬

    Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

    • [ ] Test A
    • [ ] Test B

    Test Configuration: πŸ”§

    • Firmware version:
    • Hardware:
    • Toolchain:
    • SDK:

    Checklist: βœ…

    • [ ] My code follows the style guidelines of this project
    • [ ] I have performed a self-review of my own code
    • [ ] I have commented my code, particularly in hard-to-understand areas
    • [ ] I have made corresponding changes to the documentation
    • [ ] My changes generate no new warnings
    • [ ] I have added tests that prove my fix is effective or that my feature works
    • [ ] New and existing unit tests pass locally with my changes
    • [ ] Any dependent changes have been merged and published in downstream modules
    patch 
    opened by ThomasAribart 0
  • feature: create redux-event-storage-adapter package

    feature: create redux-event-storage-adapter package

    Description 🦫

    Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

    Fixes # (issue)

    Type of change πŸ“

    Please delete options that are not relevant.

    • [ ] Bug fix (non-breaking change which fixes an issue)
    • [ ] New feature (non-breaking change which adds functionality)
    • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
    • [ ] This change requires a documentation update

    How Has This Been Tested? πŸ§‘β€πŸ”¬

    Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

    • [ ] Test A
    • [ ] Test B

    Test Configuration: πŸ”§

    • Firmware version:
    • Hardware:
    • Toolchain:
    • SDK:

    Checklist: βœ…

    • [ ] My code follows the style guidelines of this project
    • [ ] I have performed a self-review of my own code
    • [ ] I have commented my code, particularly in hard-to-understand areas
    • [ ] I have made corresponding changes to the documentation
    • [ ] My changes generate no new warnings
    • [ ] I have added tests that prove my fix is effective or that my feature works
    • [ ] New and existing unit tests pass locally with my changes
    • [ ] Any dependent changes have been merged and published in downstream modules
    minor 
    opened by ThomasAribart 0
  • fix: use toggles for tech descriptions in README

    fix: use toggles for tech descriptions in README

    Description 🦫

    Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

    Fixes # (issue)

    Type of change πŸ“

    Please delete options that are not relevant.

    • [ ] Bug fix (non-breaking change which fixes an issue)
    • [ ] New feature (non-breaking change which adds functionality)
    • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
    • [ ] This change requires a documentation update

    How Has This Been Tested? πŸ§‘β€πŸ”¬

    Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

    • [ ] Test A
    • [ ] Test B

    Test Configuration: πŸ”§

    • Firmware version:
    • Hardware:
    • Toolchain:
    • SDK:

    Checklist: βœ…

    • [ ] My code follows the style guidelines of this project
    • [ ] I have performed a self-review of my own code
    • [ ] I have commented my code, particularly in hard-to-understand areas
    • [ ] I have made corresponding changes to the documentation
    • [ ] My changes generate no new warnings
    • [ ] I have added tests that prove my fix is effective or that my feature works
    • [ ] New and existing unit tests pass locally with my changes
    • [ ] Any dependent changes have been merged and published in downstream modules
    patch 
    opened by ThomasAribart 0
  • fix: Use vitest

    fix: Use vitest

    Description 🦫

    Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

    Fixes # (issue)

    Type of change πŸ“

    Please delete options that are not relevant.

    • [ ] Bug fix (non-breaking change which fixes an issue)
    • [ ] New feature (non-breaking change which adds functionality)
    • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
    • [ ] This change requires a documentation update

    How Has This Been Tested? πŸ§‘β€πŸ”¬

    Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

    • [ ] Test A
    • [ ] Test B

    Test Configuration: πŸ”§

    • Firmware version:
    • Hardware:
    • Toolchain:
    • SDK:

    Checklist: βœ…

    • [ ] My code follows the style guidelines of this project
    • [ ] I have performed a self-review of my own code
    • [ ] I have commented my code, particularly in hard-to-understand areas
    • [ ] I have made corresponding changes to the documentation
    • [ ] My changes generate no new warnings
    • [ ] I have added tests that prove my fix is effective or that my feature works
    • [ ] New and existing unit tests pass locally with my changes
    • [ ] Any dependent changes have been merged and published in downstream modules
    patch 
    opened by ThomasAribart 0
  • fix: improve the test tools documentation

    fix: improve the test tools documentation

    Description 🦫

    Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

    Fixes # (issue)

    Type of change πŸ“

    Please delete options that are not relevant.

    • [ ] Bug fix (non-breaking change which fixes an issue)
    • [ ] New feature (non-breaking change which adds functionality)
    • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
    • [ ] This change requires a documentation update

    How Has This Been Tested? πŸ§‘β€πŸ”¬

    Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

    • [ ] Test A
    • [ ] Test B

    Test Configuration: πŸ”§

    • Firmware version:
    • Hardware:
    • Toolchain:
    • SDK:

    Checklist: βœ…

    • [ ] My code follows the style guidelines of this project
    • [ ] I have performed a self-review of my own code
    • [ ] I have commented my code, particularly in hard-to-understand areas
    • [ ] I have made corresponding changes to the documentation
    • [ ] My changes generate no new warnings
    • [ ] I have added tests that prove my fix is effective or that my feature works
    • [ ] New and existing unit tests pass locally with my changes
    • [ ] Any dependent changes have been merged and published in downstream modules
    patch 
    opened by ThomasAribart 0
  • feature: create muteEventStore util in test-tools

    feature: create muteEventStore util in test-tools

    Description 🦫

    Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

    Fixes # (issue)

    Type of change πŸ“

    Please delete options that are not relevant.

    • [ ] Bug fix (non-breaking change which fixes an issue)
    • [ ] New feature (non-breaking change which adds functionality)
    • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
    • [ ] This change requires a documentation update

    How Has This Been Tested? πŸ§‘β€πŸ”¬

    Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

    • [ ] Test A
    • [ ] Test B

    Test Configuration: πŸ”§

    • Firmware version:
    • Hardware:
    • Toolchain:
    • SDK:

    Checklist: βœ…

    • [ ] My code follows the style guidelines of this project
    • [ ] I have performed a self-review of my own code
    • [ ] I have commented my code, particularly in hard-to-understand areas
    • [ ] I have made corresponding changes to the documentation
    • [ ] My changes generate no new warnings
    • [ ] I have added tests that prove my fix is effective or that my feature works
    • [ ] New and existing unit tests pass locally with my changes
    • [ ] Any dependent changes have been merged and published in downstream modules
    minor 
    opened by ThomasAribart 0
Releases(v1.7.0)
  • v1.7.0(Dec 26, 2022)

    Changes

    • feature: Remove timestamp from pushEvent input (set it automatically) @ThomasAribart (#40)
    • fix: remove lodash from dependencies @ThomasAribart (#39)
    Source code(tar.gz)
    Source code(zip)
  • v1.6.0(Dec 24, 2022)

    Changes

    • fix: use redux-event-storage-adapter in demo/visualization @ThomasAribart (#38)
    • feature: create redux-event-storage-adapter package @ThomasAribart (#37)
    • fix: use toggles for tech descriptions in README @ThomasAribart (#36)
    Source code(tar.gz)
    Source code(zip)
  • v1.5.1(Dec 22, 2022)

  • v1.5.0(Dec 21, 2022)

    Changes

    • fix: improve the test tools documentation @ThomasAribart (#34)
    • feature: create muteEventStore util in test-tools @ThomasAribart (#33)
    • fix: fix mistakes in documentation @ThomasAribart (#32)
    • feature: Implement commands retry at command level @ThomasAribart (#31)
    Source code(tar.gz)
    Source code(zip)
  • v1.4.4(Dec 20, 2022)

  • v1.4.3(Nov 25, 2022)

  • v1.4.2(Nov 18, 2022)

    Changes

    • fix: fix typos in READMEs @ThomasAribart (#27)
    • chore: document json-schema-command package @ThomasAribart (#26)
    • chore: document event types @ThomasAribart (#25)
    • chore: finish readme @ThomasAribart (#24)
    • chore: update README @charlesgery (#21)
    • chore: add documentation on storage adapters @ThomasAribart (#23)
    Source code(tar.gz)
    Source code(zip)
  • v1.4.1(Nov 4, 2022)

  • v1.4.0(Oct 28, 2022)

    Changes

    • feature: Improve documentation @ThomasAribart (#19)
    • feature: rework EventDetail for more simplicity @ThomasAribart (#18)
    • feature: Enable settings DynamoDB table name dynamically @ThomasAribart (#17)
    Source code(tar.gz)
    Source code(zip)
  • v1.3.1(Oct 6, 2022)

  • v1.3.0(Oct 5, 2022)

    Changes

    • feature: Add reverse and limit options in event fetching @ThomasAribart (#16)
    • feature: add snapshot configuration in EventStore @valentinbeggi (#11)
    Source code(tar.gz)
    Source code(zip)
  • v1.2.1(Sep 13, 2022)

  • v1.2.0(Aug 26, 2022)

    Changes

    • feature: improvement of mockEventStore @julietteff (#8)
    • chore: clarify workflows @ThomasAribart (#14)
    • feature: enable events transaction in dynamodb adapter @ThomasAribart (#12)
    • feature: :package: isolate jsonSchemaCommand in a package @valentinbeggi (#1)
    Source code(tar.gz)
    Source code(zip)
  • v1.1.3(Aug 12, 2022)

  • v1.1.2(Aug 12, 2022)

  • v1.1.1(Aug 12, 2022)

Owner
castore
Better DevX for Event Sourcing in TypeScript πŸ§‘β€πŸ’»
castore
Grupprojekt fΓΆr kurserna 'Javascript med Ramverk' och 'Agil Utveckling'

JavaScript-med-Ramverk-Laboration-3 Grupprojektet fΓΆr kurserna Javascript med Ramverk och Agil Utveckling. Utvecklingsguide FΓΆr information om hur utv

Svante Jonsson IT-HΓΆgskolan 3 May 18, 2022
Hemsida fΓΆr personer i Sverige som kan och vill erbjuda boende till mΓ€nniskor pΓ₯ flykt

Getting Started with Create React App This project was bootstrapped with Create React App. Available Scripts In the project directory, you can run: np

null 4 May 3, 2022
Kurs-repo fΓΆr kursen Webbserver och Databaser

Webbserver och databaser This repository is meant for CME students to access exercises and codealongs that happen throughout the course. I hope you wi

null 14 Jan 3, 2023
Tax-finder - A web application sourcing and sharing tax data on Fortune 500 corporations.

This is a Next.js project bootstrapped with create-next-app. Getting Started First, run the development server: npm run dev # or yarn dev Open http://

Bennett Huffman 1 Jan 1, 2022
Quickly create an interactive HTML mock-up by auto sourcing lorem ipsum/images generators, with minimal html markup, and no server side code

RoughDraft.js v0.1.5 Quickly mockup / prototype HTML pages with auto-generated content, without additional JavaScript or server side code. <section>

Nick Dreckshage 464 Dec 21, 2022
io-ts Typed Event Bus for the runtime of your Node.js application. A core for any event-driven architecture based app.

Typed Event Bus Based on io-ts types, this bus provides a handy interface to publish and consume events in the current runtime of the Node.js process.

Konstantin Knyazev 3 May 23, 2022
'event-driven' library aims to simplify building backends in an event driven style

'event-driven' library aims to simplify building backends in an event driven style(event driven architecture). For message broker, light weight Redis Stream is used and for event store, the well known NoSQL database, MongoDB, is used.

Sihoon Kim 11 Jan 4, 2023
A TypeScript friendly event emitter with easy re-emitting events

remitter A TypeScript friendly event emitter with easy re-emitting events. Install npm add remitter Usage import { Remitter } from "remitter"; interf

CRIMX 5 Dec 28, 2022
A small library aims to improve better tagged-unions/discriminated-unions supporting for TypeScript

coproduct A small library aims to improve better tagged-unions/discriminated-unions supporting for TypeScript Benefits Small bundled size(just 1kb) Ea

ε·₯业聚 29 Aug 15, 2022
Mongo Strict is a TypeScript based smart MongoDB ORM, It makes the usage of MongoDB safer, easier and faster with a better performance...

mongo-strict mongo-strict is compatible with mongo >= 5 Mongo Strict is a TypeScript-based smart MongoDB ORM, It makes the usage of MongoDB safer, eas

Mohamed Kamel 4 Sep 22, 2022
Examples of how to do query, style, dom, ajax, event etc like jQuery with plain javascript.

You (Might) Don't Need jQuery Frontend environments evolve rapidly nowadays and modern browsers have already implemented a great deal of DOM/BOM APIs

NEFE 20.3k Dec 24, 2022
Work around some mobile browser's 300ms delay on the click event.

jQuery fastClick plugin Work around the 300ms delay for the click event in some mobile browsers (e.g. Android and iOS). Code based on http://code.goog

Dave Hulbert 132 Jul 6, 2020
A lightweight normalized tap event

?? Retired: Tappy! Per our unmaintained repository status documentation this repository is now retired and is no longer accepting issue reports or pul

Filament Group 573 Dec 9, 2022
An event emitter that allows you to manage your global state

Thor Event Emitter Event emitter to manage your state. An event emitter that allows you to manage your global state. Instead of using global giant obj

Jalal 6 Apr 18, 2022
Event scheduler is a simple app for viewing the events happening around you

Event scheduler is a simple app for viewing the events happening around you. User can also create their event and include a location. Location can also be marked as hidden(strictly by IV). Built with React and Styled Components

Anselem Odimegwu 3 Mar 29, 2022
The invoker based on event model provides an elegant way to call your methods in another container via promisify functions

The invoker based on event model provides an elegant way to call your methods in another container via promisify functions. (like child-processes, iframe, web worker etc).

尹挚 7 Dec 29, 2022
πŸ³οΈβ€πŸŒˆ event calendar

alman-akka :rainbow-flag: event calendar Frontend The frontend of this app uses NextJS and Node 16 together with Yarn 1.x as a package manager. Develo

null 3 Mar 10, 2022
An event-driven architecture wrapper for Wechaty that applies the CQS principle by using separate Query and Command messages to retrieve and modify the bot state, respectively.

CQRS Wechaty An event-driven architecture wrapper for Wechaty that applies the CQS principle by using separate Query and Command messages to retrieve

Wechaty 3 Mar 23, 2022
Real-time event collaborating

Smartlist Collaborate Collaborate on your events in real-time! An product by Smartlist ?? This product is still in development, and some features mig

Smartlist 2 Mar 17, 2022