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 🙏

© 2024 – Pkg Stats / Ryan Hefner

dev-tool

v1.0.5

Published

devTool for 乐居网平台组前端

Downloads

28

Readme

THIS IS AN PERSONAL NODE_MODULE. DO NOT USE IT

devTool

devTool for 乐居网平台组前端

说明

提供本地的web前端开发环境。

  1. 静态文件服务 访问静态资源

  2. combo服务 combo可支持在线r.js解析,在线编译less/sass的功能 url示例: /public/a.css;/public/b.css /public/a.js;/public/b.js /public/a.js?r /public/a.less /public/a.sass

  3. 代理服务器服务 提供反向代理,设置本地hosts的功能 配置文件示例:

    {
    	"proxy_port": 1080,
    	"proxy_hosts": [
    		"127.0.0.1 www.test.com dev.com"
    	],
    	"proxy_rules": [
    		// rule: match-url target-server
    		// The latter rule would overwrite the previous rules
    		"http://cdn\\d?.exmaple.com http://11.22.33.44", // #1 remote address
    		"http://cdn(\\d)?.exmaple.com/test/(.+) http://cdn$1.test.com:8080" // #2 local address
    	]
    }

上面的配置将把http://cdn.exmaple.com/test/a.js 指向 127.0.0.1:8080, 而http://cdn.exmaple.com/a.js 将指向 11.22.33.44

注: 可以通过在cwd目录下建一个devtool.json来覆盖默认配置,修改本地的配置需要重启devtool才生效。

安装方法

npm i -g dev-tool

使用方法

Usage: devtool [options] directory

Options:

  -h, --help                 output usage information
  -V, --version              output the version number
  -p, --port <port>          static server port
  -c, --combo [true|false]   use combo server
  -s, --static [true|false]  use static server
  -r, --proxy [false|true]   use proxy server
  -o, --proxy_port <port>    proxy server port

todo

  • 支持 mockjson 功能