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

swift-web-cli

v0.6.19

Published

swift web cli

Downloads

2

Readme

后台管理前端界面脚手架

后台管理前端界面脚手架

安装 nodejs (已经安装请忽略)

  • nodejs https://nodejs.org/zh-cn/

测试 node 是否安装成功

npm -v

安装全局依赖(已经安装请忽略)

npm i -g yarn nrm serve 
  • nrm 管理 npm 源 https://github.com/Pana/nrm
  • yarn 比 npm 更快 https://yarnpkg.com/zh-Hans/docs/usage
  • serve 开启一个本地静态服务器 https://github.com/zeit/serve#readme

搭建内网 npm 服务(已经搭建请忽略)

目前已经有了,源地址: http://192.168.192.222:4873/ 当然,想自己搭一个,也比较简单:https://github.com/rlidwka/sinopia 请使用 nrm 管理源

安装 swift-web-cli(已经安装请忽略)

npm install swift-web-cli -g --registry=http://192.168.192.222:4873/

创建新项目/创建子项目/同步最新模版配置

初始化新项目

swift-web-cli -i # 然后键入项目名称,必须英文变量 i = init

创建子项目

cd 初始化的项目目录
npm run create # 然后键入子项目名称,必须英文变量

同步最新模版

cd 初始化的项目目录
npm run sync

运行与打包

运行

cd /对应项目目录
yarn # 如果已经安装则不需要
npm start

打包

cd /对应项目目录
yarn # 如果已经安装则不需要
npm run build

编写样式注意事项

由于,需要做到多主题,颜色请使用变量,而不是写死,已经有的变量: https://github.com/ant-design/ant-design/blob/master/components/style/themes/default.less

@todos

  • 打包成单页面
  • 常用快捷键,(比如关闭tab标签页等)
  • 编辑主题改进,比如可视化等
  • 更多模版:不一样形式的后台界面展现和交互形式