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

fkc-cli

v1.0.3

Published

一个脚手架,通过交互式命令从Gitlab、 Github中下载模版代码生成新项目,不需要每次都配置项目脚手架,也不需要每次都copy 原来项目文件,删删减减。

Downloads

3

Readme

fkc-cli-tpl

一个脚手架,通过交互式命令从Gitlab、 Github中下载模版代码生成新项目,不需要每次都配置项目脚手架,也不需要每次都copy 原来项目文件,删删减减。

安装

npm i fkc-cli -g

输入「fkc」了解脚手架

fkc

fkc-cli

查看所有模版

fkc-cli

fkc

创建项目

fkc init react-vw-layout demo-project

fkc

项目创建完毕

fkc

fkc-cli 脚手架参考

脚手架的作用

  1. 减少重复性的工作,不需要复制其他项目再删除无关代码,或者从零创建一个项目和文件。
  2. 可以根据交互动态生成项目结构和配置文件。
  3. 多人协作更为方便,不需要把文件传来传去。

参考思路

  1. 项目模板放在Gitlab、 Github上 。
  2. 用户通过命令交互的方式下载不同的模版 。
  3. 经过模版引擎渲染定制项目模版 。
  4. 模版变动,只需更新模版即可,不需要用户更新脚手架 。

设计模块知识点

  1. commander.js命令行工具 。
  2. download-git-repo: 用来下载远程模板 。
  3. inquirer: 交互式命令行工具 。
  4. ora: 显示loading动画 。
  5. chalk: 修改控制台输出内容样式 。
  6. log-symbols: 显示出 √ 或 × 等的图标 。

参考文档

Node.js 命令行程序开发教程

download-git-repo包从远程(GitHub, GitLab, Bitbucket)拉取文件到本地

commander.js包 在命令行中显示

Ora 在控制台显示当前加载状态的

shelljs 模块重新包装了 child_process,调用系统命令

yargs 获取命令行参数

chalk 控制控制台输出文字的颜色

搭一个属于自己的脚手架