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 🙏

© 2025 – Pkg Stats / Ryan Hefner

@gaiot/apis

v2.4.5

Published

aiot apis

Readme

git 使用文档 | 组件库使用文档

组件库使用文档

项目结构

sdk/
 |-.husky
 |-.storybook
 |-dist/
 |-example/
   |-App.tsx
   |-main.tsx
 |-node_modules/
 |-packages/
   |-api/
     |-common
       |-base.api.ts
       |-base.model.ts
     |-panorama
       |-index.ts
       |-model.ts
     |-index.ts
   |-react-biz-components/
     |-PanoramaMap
       |-index.ts
       |-style.less
   |-react-components/
     |-Button
       |-index.ts
       |-style.less
   |-index.tsx
 |-public/
 |-stories/
   |-Button/
     |-Button.stories.tsx
 |-package.json
 |-index.html
 |-vite.config

| 目录/文件 | 作用介绍 | | ---------- | --------------------------- | | .storybook | 文档预览服务的配置文件 | | dist | 打包文件,上传到 npm 上的包 | | example | 开发组件挂在在 root | | packages | 需要开发的组件 | | stories | 需要生成预览文档的组件 |

组件开发

1、项目启动: npm run dev

2、预览:http://localhost:3000

3、App.tsx 中引入 packages 中开发的组件,example 中示例如下:

import React from 'react';
import { Button } from '../packages/index';
const Test = () => {
  return (
    <div>
      <Button label="按钮" primary></Button>
    </div>
  );
};

export default Test;

组件发布

1、执行npm run build打包文件

2、命令行使用npm login登录 npm

3、使用npm publish发布

package.json 上定义的基础入口信息和类型声明

  {
	  "name": "aiot-panorama-jssdk",
	  "private": false,
	  "version": "0.0.2",
	  "description": "React components",
	  "type": "module",
	  "keywords": [
		"react",
		"react-component"
	  ],
	  "files": [
		"dist"
	  ],
	  "main": "./dist/aiot-panorama-jssdk.umd.cjs",
	  "module": "./dist/aiot-panorama-jssdk.js",
	  "typings": "./dist/index.d.ts",
	  "exports": {
		".": {
		  "import": "./dist/aiot-panorama-jssdk.js",
		  "require": "./dist/aiot-panorama-jssdk.umd.cjs"
		},
		"./style.css": "./dist/style.css"
	  },
	  "repository": "",
	  "author": "gspace",
	  "license": "MIT"
  }

组件使用

安装

yarn add aiot-panorama-jssdk

使用

import { Button } from 'aiot-panorama-jssdk';
import "aiot-panorama-jssdk/style.css"

<Button label="按钮" primary></Button>

附:

storybook 中文使用文档

storybook 英文使用文档