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

@nichengkai/express

v1.1.2

Published

Make your Express register routes with decorators.

Downloads

97

Readme

Express-TypeScript

TypeScript 版本的 Express 框架,支持使用装饰器注册路由

安装

npm i @nichengkai/express-resource -S

使用

注册路由

装饰器参数都为必填

控制器装饰器

参数为跟路径

@Controller('/root')

路由装饰器

参数为 URL 地址

@Get('/')
@Put('/')
@Post('/')
@Patch('/')
@Delete('/')

注册定时任务

开启任务

写了以后才会执行任务

@Task

循环任务

可选单位 ms s min h D W M Y

@Loop('100ms')

定时任务

默认值:@Time('00:00:00'), 如果设置了 @Week 或者 @Month,没有设置 @Time, 则默认零点执行。

// 设置时间
@Time('00:00')
@Time('00:00:00')
// 设置周
@Week('1')
// 设置月
@Month('15')
使用试例
  1. 每天下午一点执行
@Time('13:00')
  1. 每周一中午十二点执行
@Week('1')
@Time('12:00')
  1. 每个月 15 号上午十点执行
@Month('15')
@Time('10:00')