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

ty-cli-market

v1.2.0

Published

帮助手册完善

Downloads

19

Readme

基础命令

1. npm 全局安装
npm i ty-cli-market -g

2. 快捷键 ty/ty-cli

3. 帮助命令 ty -h
Usage: ty-cli <command> [options]

A simple CLI tool for string manipulation

Options:
-V, --version                    output the version number
-h, --help                       display help for command

Commands:
create [options] <project-name>  create a new project
help [command]                   display help for command

Run ty-cli <command> --help for detailed usage of given command.

4. 版本查看 ty -V
1.1.0

模板创建

create 命令也就是脚手架的核心指令,用来选择不同的执行模板并下载

  1. 配置命令的基本信息
  2. 解析后面的 options 响应参数
    1. 存在 force 参数,直接下载
    2. 不存在 force 参数,判断是否有重名的模板,给用户选择是否覆盖
      1. 退出本次操作
      2. 覆盖当前文件
  3. 一步步确认模板的类型
  4. github 拉取项目信息
  5. 下载模板到本地

命令帮助

5.png

选择模板

6.png

开始创建

7.png

9.png

开发模板

10.png 当前是小程序的开发模板,具体模板使用说明可以查看相关文档。

开发背景

目前团队内部后台管理系统过多,需求开发的页面逻辑或者相关组件重复率过高,跨项目开发很容易遇到重复编写大量代码、不同项目的技术栈/版本不统一、相关样式不统一等问题,迫切需要一款标准化、高扩展、简单便捷的脚手架工具来协助开发。 该工具要求具备的核心能力如下:

  1. 命令行运行,多种配置可选,可自定义
  2. 配色方案、核心布局、组件、方法、hooks、http 请求封装完备
  3. 设计高扩展性,同程内部的工具链路完备

问题记录

模板创建超时

8.png Git 客户端无法在指定的时间内连接到 GitHub 服务器上的 443 端口

取消全局 Git 配置中设置的 HTTPS 代理服务器
git config --global --unset http.proxy
git config --global --unset https.proxy

更新日志

  1. 2024-6-30 V1.0.0 第一版上线
  2. 2024-7-1 后续 create 命令优化
  3. 2024-7-3 说明文档 V1.0.1
  4. 2024-7-8 GitHub API 权限认证 V1.1.0
  • [ ] GitHub 会有网络问题,后续整体迁移到 GitLab
  • [ ] 模板定制化选择,维度包括:语言版本、组件库、功能细分
  • [ ] 后台管理系统模板优化开发