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

just-spa

v1.2.4

Published

Just是一套前端工程化工具,支持web主流和小程序技术栈,用户对物料库进行处理,快速进行组件的创建、开发、调试、打包构建。从而提高组件开发效率,统一组件规范,分离组件功能并减少人员变动给项目维护带来的额外成本

Downloads

469

Readme

Getting Started

  Just-spa是一套前端组件工程化工具,可以帮助开发者对物料库进行调用处理,快速进行组件和应用的创建、开发、调试、打包构建,可管理的组件支持React、Vue、Angular或jquer等主流技术栈。从而提高组件管理和开发效率、统一组件规范并分离组件功能、减少人员变动给项目维护带来的额外成本。

  相对于vue-cli,react-create-app等常用脚手架,Just-spa不仅根据业务实践提取了最佳实践的组件和项目物料模板,帮您快速生成各类组件和项目工程,而且对于组件和项目提供了便捷清晰的界面化预览、hot调试、管理、测试、打包、Mock等功能。当然,你也可以根据提供的规范快速地扩展自己需要使用的物料模板。

1、安装just-spa

npm i just-spa -g

  如果您设置了tnpm等代理命令,请使用 tnpm i just-spa -g 来安装。

2、快速创建和调试一个组件

  选择一个本地工作目录,打开终端执行:

just init

  输入生成组件的相关信息,填写名称、物料库等,即可快速生成组件。创建组件完成后执行:

just watch

  just watch会开启组件实时watch同步调试, 然后在相同目录中开启另一个终端执行:

just start

  just start会启动调试服务器,此时just会自动拉起浏览器打开 http://localhost:8000 ,即可看到调试组件的列表并查看just工具的详细文档。如下:

  

  点击一个组件进入就可以界面化预览、hot调试、管理、测试、打包、Mock你的组件了。另外组件对应的文档也会使用jsdoc2md自动帮你生成。开发者只需要关注开发组件的代码就可以了。

  

  

  

3、快速创建项目

  快速创建项目目前支持react、PWA、redux、spa等多类项目的快速创建,和创建组件类似的简单:

just webapp

  生成后进入目录,执行 npm inpm run dev即可启动项目调试。目前集成了PC端SPA和移动端SPA的项目模板(可支持PWA),创建完成即可使用。

4、just帮助命令

  此外你可以执行just help来查看just的其它命令和功能。

just init: 创建一个组件或项目。根据组件物料库快速生成一个组件或项目。

just template: 根据自定义组件物料库目录创建一个新的组件物料库。

just rmtemplate: 删除一个自定义组件物料库。

just list: 查看存在的所有组件物料库列表。

just webapp: 调用项目物料库快速生成一个项目工程。

just i/install: 安装组件的第三方依赖,同 npm/tnpm install。

just update: 更新组件的第三方依赖,同 npm/tnpm update。

just start/run -port: 启动调试服务器。一般只需要运行一次。-p或-port表示指定端口开启服务。

just clear/clean: 清除缓存。清除build构建的缓存目录。

just dev/watch: 在当前目录下创建组件调试环境。

just build: 编译打包组件为单个输出的ES5文件并编译CSS文件。例如:just build ComponentName

just help: 查看帮助。查看just所有命令。

just -v/version: 显示当前安装的just版本。

just set: 设置npm、tnpm或tnpm,例如:just set tnpm。

  具体功能用法可以查看./src/docs目录或工具界面右上角或者详细文档