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

test-module001

v1.0.0

Published

用于测试的目的

Downloads

1

Readme

测试

首先你需要安装 NodeJS

前端工程环境基于Node运行的,Node会自带Npm包管理工具,在控制台运行 npm ,如果打印出提示,则说明node安装成功。

然后安装前端工程环境的依赖

你需要运行 npm install,即可自动安装依赖。但是,由于网络连接不稳定,以及npm自身的缺陷,在不同的时期安装的依赖包不能保证一致,甚至有可能安装失败。可以从其它成功安装的同学处将依赖包拷贝到本地即可。

启动本地开发环境,并同时进行前后端联调

你需要运行 npm start,然后打开浏览器,访问 http://localhost:4200/ 即可。 如果你修改了源码的任意部分,app会自动编译和重新加载。 当然,你必须要在 proxy.conf.json 文件中填写正确的服务端IP才能正常联调。

代码脚手架

你可以完全手动地创建一个组件、服务或者其它的部件,但是个人还是建议通过如下命令来快速创建部件,它可以自动生成符合规范的代码命名、添加测试代码模板和添加模块引用,尤其对于初学者又很有帮助。 Component(组件): npm run ng g component ./core/my-new-component Directive(指令): npm run ng g directive ./core/my-new-directive Pipe(管道): npm run ng g pipe ./core/my-new-pipe Service(服务): npm run ng g service ./core/my-new-service Class(类): npm run ng g class ./core/my-new-class Interface(接口): npm run ng g interface ./core/my-new-interface Enum(枚举): npm run ng g enum ./core/my-new-enum Module(模块): npm run ng g module ./core/my-module

编译

运行 npm run build 编译项目。

运行单元测试

运行 ng test 执行单元测试,参见 Karma.

运行端对端测试(end-to-end)

运行 ng e2e 执行 end-to-end 测试,参见 Protractor. 测试前请确保已经通过 ng serve 命令启动了开发模式。