Skip to content

Expressive-Tea/packages

Expressive Tea Packages

Monorepo for foundational Expressive Tea framework packages

npm version npm version npm version license

📅 Versioning: All packages use Calendar Versioning (CalVer) in the format YYYY.MM.MICRO. Current version: 2026.1.0


Important

🔄 Version Compatibility Notice

These packages (v2026.1.0) are designed for @expressive-tea/core >= 2.0.0

  • Compatible with: @expressive-tea/core v2.x.x and above
  • Not compatible with: @expressive-tea/core v1.x.x or below

For Core v1.x users:

  • Use @expressive-tea/commons@1.0.1 (last SemVer version for Core v1.x)
  • Use @expressive-tea/plugin@1.0.3 (last SemVer version for Core v1.x)
  • Note: @expressive-tea/metadata did not exist for Core v1.x

📖 Versioning: See VERSIONING.md for complete CalVer policy details.


Description

This monorepo contains the foundational packages for the Expressive Tea framework ecosystem. These packages provide core utilities, metadata management, and plugin architecture capabilities used by @expressive-tea/core and other Expressive Tea projects.

Current Version: 2026.1.0 (CalVer format: YYYY.MM.MICRO)
Versioning Scheme: Calendar Versioning (CalVer) - independent from Core's SemVer

Packages

npm version npm downloads

Framework-agnostic TypeScript metadata management utilities for decorators.

Features:

  • ✨ Comprehensive metadata management API
  • 🎨 5 pre-built decorator utilities (@SetMetadata, @Meta, @InheritMetadata, @CacheInMetadata, @Deprecated)
  • 🔒 Type-safe with full TypeScript support
  • 🪶 Lightweight with minimal dependencies
  • 🌐 Framework-agnostic (works with any TypeScript project)

Install:

npm install @expressive-tea/metadata reflect-metadata

📖 Full Documentation →


npm version npm downloads

Core utilities and shared types for the Expressive Tea framework.

Features:

  • ✨ Re-exports all metadata functionality from @expressive-tea/metadata
  • 🎯 TypeScript-first with full type definitions
  • 🔒 Strict mode enabled for maximum type safety
  • 📦 Lightweight (re-export layer for backward compatibility)

Install:

npm install @expressive-tea/commons reflect-metadata

📖 Full Documentation →


npm version npm downloads

Plugin architecture system for building modular, reusable application components.

Features:

  • 🔌 Plugin system with lifecycle hooks (boot stages)
  • 🔗 Dependency management between plugins
  • ⚡ Priority-based execution order
  • 🎨 Decorator-driven API with @Stage

Install:

npm install @expressive-tea/plugin reflect-metadata

📖 Full Documentation →


Quick Start

Installation

# Install both packages
npm install @expressive-tea/commons @expressive-tea/plugin reflect-metadata

# Or with yarn
yarn add @expressive-tea/commons @expressive-tea/plugin reflect-metadata

Usage Example

Using Commons:

import 'reflect-metadata';
import { Metadata } from '@expressive-tea/commons';

class UserController {
  @Route('/users')
  getUsers() {
    return [];
  }
}

function Route(path: string) {
  return function (target: any, propertyKey: string) {
    Metadata.set('route:path', path, target, propertyKey);
  };
}

const routePath = Metadata.get('route:path', UserController.prototype, 'getUsers');
console.log(routePath); // '/users'

Using Plugin:

import { Plugin, BOOT_STAGES, Stage } from '@expressive-tea/plugin';
import { Express } from 'express';

export class LoggerPlugin extends Plugin {
  protected name = 'LoggerPlugin';
  protected priority = 100;

  @Stage(BOOT_STAGES.APPLICATION)
  setupLogger(server: Express): void {
    server.use((req, res, next) => {
      console.log(`${req.method} ${req.path}`);
      next();
    });
  }
}

Requirements

  • Node.js ≥ 18.0.0
  • TypeScript ≥ 5.0.0 (if using TypeScript)
  • reflect-metadata 0.2.x

What's New in v2.0.0

Major modernization release!

✨ Added

  • ✅ Comprehensive test coverage (94%+) with Jest 30
  • ✅ Full JSDoc documentation on all public APIs
  • ✅ ESLint v9 with flat config and type-aware linting
  • ✅ Prettier code formatting
  • ✅ TypeScript strict mode enabled
  • ✅ Native utility functions (removed lodash)
  • ✅ GitHub issue/PR templates and community files

🔧 Changed

  • ⬆️ Upgraded to TypeScript 5.9.3
  • ⬆️ Upgraded to Yarn 4.11.0 workspaces
  • 📁 Build output moved to dist/ directories
  • 🚀 Replaced Gulp with native TypeScript compilation
  • 📚 Enhanced IDE support with comprehensive JSDoc

🗑️ Removed

  • ❌ TSLint (replaced with ESLint v9)
  • ❌ Lodash dependency (replaced with native JS)
  • ❌ Gulp build system

⚠️ Breaking Changes

  • Node.js 18+ required (was: no minimum)
  • TypeScript 5+ required (was: 3.6+)
  • Build output moved to dist/ (was: co-located)

📖 Full Migration Guide →


Development

This is a Yarn 4 workspaces monorepo. Here's how to work with it:

Setup

# Clone the repository
git clone https://github.com/Expressive-Tea/packages.git
cd expresive-tea/packages

# Install dependencies (requires Yarn 4)
yarn install

Build

# Build all packages
yarn build

# Clean build artifacts
yarn clean

# Clean then build
yarn clean && yarn build

Testing

# Run all tests
yarn test

# Run tests in watch mode
yarn test:watch

# Clear Jest cache
yarn test:clear

# Run tests for a specific package
cd packages/commons && yarn test
cd packages/plugin && yarn test

Linting & Formatting

# Lint all packages
yarn lint

# Lint and auto-fix
yarn lint:fix

# Format code
yarn format

# Check formatting
yarn format:check

Type Checking

# Type check commons package
npx tsc --noEmit -p packages/commons

# Type check plugin package
npx tsc --noEmit -p packages/plugin

Project Structure

@expressive-tea/packages/
├── .github/                    # GitHub templates and workflows
│   ├── ISSUE_TEMPLATE/
│   │   ├── bug_report.yml
│   │   ├── feature_request.yml
│   │   └── config.yml
│   ├── PULL_REQUEST_TEMPLATE.md
│   ├── SECURITY.md
│   ├── SUPPORT.md
│   └── FUNDING.yml
├── packages/
│   ├── commons/                # @expressive-tea/commons package
│   │   ├── src/
│   │   │   ├── classes/        # Metadata management
│   │   │   ├── helpers/        # Utility functions
│   │   │   ├── types/          # TypeScript types
│   │   │   ├── __test__/       # Unit tests
│   │   │   └── index.ts        # Public API
│   │   ├── dist/               # Compiled output
│   │   ├── package.json
│   │   ├── tsconfig.json
│   │   └── README.md
│   └── plugin/                 # @expressive-tea/plugin package
│       ├── src/
│       │   ├── classes/        # Plugin base class
│       │   ├── decorators/     # @Stage decorator
│       │   ├── helpers/        # Storage and utilities
│       │   ├── libs/           # Native utilities
│       │   ├── exceptions/     # Error classes
│       │   ├── constants.ts    # BOOT_STAGES enum
│       │   ├── __test__/       # Unit tests
│       │   └── index.ts        # Public API
│       ├── dist/               # Compiled output
│       ├── package.json
│       ├── tsconfig.json
│       └── README.md
├── AGENTS.md                   # AI agent coding guidelines
├── CONTRIBUTING.md             # Contribution guidelines
├── MIGRATION.md                # Migration guide v0.0.x → v2.0.0
├── README.md                   # This file
├── package.json                # Workspace root package.json
├── tsconfig.json               # Base TypeScript config
├── tsconfig.linter.json        # TypeScript config for ESLint
├── eslint.config.js            # ESLint v9 flat config
├── .prettierrc                 # Prettier configuration
├── jest.config.js              # Jest root configuration
└── yarn.lock                   # Yarn 4 lockfile

Contributing

We welcome contributions! Whether it's bug fixes, features, or documentation improvements.

Before contributing, please:

  1. Read the Contributing Guide
  2. Check the AI Agent Guidelines if using AI coding tools
  3. Review existing Issues and Pull Requests

Development Workflow:

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/my-feature
  3. Make your changes and add tests
  4. Run tests: yarn test
  5. Lint your code: yarn lint
  6. Format your code: yarn format
  7. Commit using Conventional Commits:
    • feat: add new feature
    • fix: resolve bug
    • docs: update documentation
    • test: add tests
  8. Push and create a pull request

Quality Standards:

  • ✅ All tests must pass (yarn test)
  • ✅ Linting must pass (yarn lint)
  • ✅ Code must be formatted (yarn format)
  • ✅ Type checking must pass (npx tsc --noEmit -p packages/*)
  • ✅ Test coverage must be maintained (>90%)
  • ✅ JSDoc documentation required for public APIs

Related Projects

Support

Getting Help

Reporting Issues

Found a bug? Please open an issue with:

  • Package name and version
  • Node.js and TypeScript versions
  • Clear description of the problem
  • Minimal reproduction code
  • Expected vs actual behavior

Security Vulnerabilities

Do not report security vulnerabilities through public GitHub issues.

Please email: security@expressive-tea.io

See Security Policy for details.

Versioning

We use Semantic Versioning (SemVer). For available versions, see the tags on this repository.

Current Versions:

  • @expressive-tea/commons@2.0.0
  • @expressive-tea/plugin@2.0.0

License

Apache-2.0 License - see LICENSE file for details.

Authors & Contributors

Original Author:

Maintained by:

See all contributors who've helped shape this project.

Acknowledgments


Made with ☕ and 🍵 by the Expressive Tea Team
Start brewing better Node.js apps today!

About

Expressive Tea Packages Repository

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Sponsor this project

Packages

 
 
 

Contributors