npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@expressive-tea/plugin

v1.0.3

Published

A Plugin Engine for Expressive Tea Framework.

Downloads

16

Readme

Expressive Tea

Expressive Tea

A Typescript Framework to create RESTful Services.

Description

Allows to user create own recipes of their own configurations for Expressive Tea Projects which will helps to agilize and repeatable patterns. In example: A User can make plugin configurations for a REST API projects and include all the express middlewwares and configurations and make it reusable. Also allows users shares their best flavored settings for new projects.

This Package is only COMPATIBLE with Expressive Tea >= 1.1.x

Installation

$ npm install @expressive-tea/plugin

Usage

Create a new file import the Plugin class and the Boot Stages as is showing in the next example:

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

export default class PluginTest extends Plugin {
	protected name: string = "Plugin Test"
	protected priority: number = 100
	protected dependencies: string[] = []

	@Stage(BOOT_STAGES.BOOT_DEPENDENCIES)
	test(server: Express) {
		server.use((req, res, next) => {
			console.log("TEST from Plugin")
			next()
		})
	}

	@Stage(BOOT_STAGES.APPLICATION)
	secondTest(server: Express) {
		server.use((req, res, next) => {
			console.log("SECOND TEST from Plugin")
			next()
		})
	}
}

Then in the file where you have setting up your Expressive Tea project you need to use the Pour decorator and made an instance of your plugin to attach it to current project.

@ServerSettings({
	port: 8080
})
@Pour(new PluginTest())
class Bootstrap extends Boot {}
const bootstrap = new Bootstrap()
bootstrap.start()

Documentation

Abstract Class Plugin

Placeholder abstract class to allow define staged methods and main information.

Properties

| Modifier | Name | Type | Description |Default | |---|---|---|---|---| | Protected | name | String | Defined the plugin name. | Class Name | | Protected | priority | Number | Defined Priority order. | 999 | | Protected | dependencies | String[]| Defined Plugin Dependencies. | [] |

abstract class Plugin {
    readonly settings: ExpressiveTeaPluginSettings;
    protected name: string;
    protected priority: number;
    protected dependencies: string[];
    private static isDependencyRegistered;
    constructor(settings?: ExpressiveTeaPluginSettings);
    getRegisteredStage(stage: BOOT_STAGES): any;
}

Stage Method Decorator

Define a Method that will be run it on a Expressive Tea defined Boot Stages.

@Stage(stage: BOOT_STAGES, required?: Boolean): (target: any, propertyKey: any, descriptor: any) => void;
method(server: Express): void;

Interfaces

interface ExpressiveTeaServerProps {
    port?: number;
    [key: string]: any;
}

interface ExpressiveTeaPluginProps {
    name: string;
    priority: number;
}

interface ExpressiveTeaPluginSettings {
    priority?: number;
    name?: string;
    dependencies?: string[];
    [key: string]: any;
}

Support

If you are experience any kind of issues we will be happy to help. You can report an issue using the issues page or the chat. You can also ask questions at Stack overflow using the expressive-tea tag.

If you want to share your thoughts with the development team or join us you will be able to do so using the official the mailing list. You can check out the wiki to learn more about Expressive Tea internals or check our documentation.

License

This project is licensed under the Apache-2.0 License - see the LICENSE file for details

Disclaimers

The banner and the logo is a derivate work Designed by Freepik