open-index/open-npm huggingface dataset:
npm package: @savehmi/sh-mobx
Description: Modern mobx wrapper with loading store, compatible with cw-mobx style usage
Author: shmi_devops
Latest version: 1.0.2

## @shmi/sh-mobx

基于 **MobX 6** 的轻量状态管理封装，兼容原 `mobx` 的使用方式，提供：

- **统一的 store 注册工具**：`use` / `toMobx` / `getAllStore`
- **异步 loading 管理**：`loadingStore` / `insetLoadingFunc`（内部使用）
- **mobx / mobx-react 透传导出**：可直接从本包使用大部分 MobX 能力

### 安装

```bash
npm install @shmi/sh-mobx
# 或
yarn add @shmi/sh-mobx
```

> 依赖：`mobx@^6`、`mobx-react@^7`，不依赖装饰器语法，完全使用函数式 API。

### 基本概念

- 一个 **store 配置** 对象形如：

```js
const userStoreConfig = {
  namespace: "user",
  state: {
    name: "",
    age: 0,
  },
  reducers: {
    setName(name) {
      this.name = name;
    },
    setAge(age) {
      this.age = age;
    },
  },
  effects: {
    *fetchUser() {
      // 支持 generator 写法（内部用 mobx.flow 包装）
    },
  },
  computeds: {
    info() {
      return `${this.name} (${this.age})`;
    },
  },
};
```

### API 说明

- **`use(storeConfigs: Array<StoreConfig>): Record<string, any>`**

  批量注册 store：

  ```js
  import { use } from "@shmi/sh-mobx";

  const stores = use([userStoreConfig, otherStoreConfig]);
  // stores.user / stores.other
  ```

- **`toMobx(storeConfig: StoreConfig): any`**

  单个配置转换为 MobX store：

  ```js
  import { toMobx } from "@shmi/sh-mobx";

  const userStore = toMobx(userStoreConfig);
  ```

- **`getAllStore(): Record<string, any>`**

  获取最近一次 `use` 注册的全部 stores：

  ```js
  import { getAllStore } from "@shmi/sh-mobx";

  const allStores = getAllStore();
  ```

- **`loadingStore`**

  内部 shape：

  ```js
  loadingStore.loading: {
    [effectId: string]: boolean;
  };
  ```

  `effectId` 规则为：`"${namespace}/${effectName}"`。

- **`connect`**

  直接透传自 `mobx-react.inject`，在 class 组件中使用：

  ```js
  import { connect } from "@shmi/sh-mobx";

  @connect(({ user }) => ({ user }))
  class UserPage extends React.Component {}
  ```

### 在项目中的典型用法

```js
// store/user.js
export const userStoreConfig = {
  namespace: "user",
  state: {
    name: "",
    age: 0,
  },
  reducers: {
    setName(name) {
      this.name = name;
    },
  },
  effects: {
    *fetchUser() {
      // 异步逻辑...
    },
  },
};

// store/index.js
import { use } from "@shmi/sh-mobx";
import { userStoreConfig } from "./user";

export const stores = use([userStoreConfig]);

// 组件中
import React from "react";
import { observer } from "@shmi/sh-mobx";
import { stores } from "../store";

const UserName = observer(() => {
  const user = stores.user;
  return <div>{user.name}</div>;
});
```

### 与原 mobX 6以下 的差异

- 内部实现基于 **MobX 6 的 `makeObservable` / `flow`**，不再使用 `decorate` 和装饰器语法。
- 对外暴露的核心 API 名称保持一致（`use` / `toMobx` / `getAllStore` / `loadingStore` / `connect`），便于平滑迁移。

"author": yzq
npm package: @savejs/npm
Description: Save your npm package namespace
Author: Nicholas Berlette
Latest version: 1.0.0-beta.1

# save.js

Save your npm package namespace.

## Install

```bash
pnpm -g add save.js
```

```bash
yarn global add save.js
```

```bash
npm i -g save.js
```

## Usage

```bash
save.js [@scope/]<package>[@version]
```

### Examples

```bash
save.js awesome-pkg@0.0.1

 > ... npm publish awesome-pkg@0.0.1
```

- - -  

## License

[MIT](https://mit-license.org) © [save.js](https://savejs.com) • inspired by npm-robbery
npm package: @saverio976/weather-monday-left-me-broken
Description: A React Native component for displaying weather with a little joke
Author: Saverio976
Latest version: 1.0.0

# weather-monday-left-me-broken

A React Native component for displaying weather using [openweathermap.org](https://openweathermap.org/current#one) with a little [joke](https://www.npmjs.com/package/monday-left-me-broken)

## INSTALL

```bash
npm install @saverio976/weather-monday-left-me-broken
```

## USAGE

```js
import Weather from 'weather-monday-left-me-broken';

// somewhere in your code:
    <Weather appid={"YOUR API KEY HERE"}/>
//
```

## DOC

- The Code is The Doc: https://github.com/Saverio976/weather-monday-left-me-broken/blob/main/src/Weather.tsx

## CONTRIBUTORS

- [Valegox](https://github.com/valegox)
- [Saverio976](https://github.com/Saverio976)