open-index/open-npm huggingface dataset:
npm package: @schach.in/clubs
Description: Data wrapper for all chess clubs of schach.in
Author: Falco Nogatz
Latest version: 1.0.2

# node.js Datenwrapper für schach.in

Package für node.js, das die Vereinsdaten aus der GeoJSON-Schnittstelle unter https://schach.in/deutschland.geojson lädt.

## Installation

```
npm install @schach.in/clubs
```

## Nutzung

```js
import Clubs from '@schach.in/clubs'
const data = await Clubs.get('karlsruher-sf-1853')
console.log(data)
```

Das Package bietet daneben ein einfaches Kommandozeilentool, um die Daten eines Vereins abzufragen:

```sh
> schach-data karlsruher-sf-1853
```

Hierfür muss das Package zuvor via `npm install -g @schach.in/clubs` global installiert werden.

## Beispielergebnis

Die Daten des JavaScript-Moduls und Kommandozeilentools haben die gleiche Form und folgen der GeoJSON-Schnittstelle. Einzig mehrere Koordinaten sind im Feld `coordinates` als Array zusammengefasst:

```json
{
  "org": "Karlsruher SF 1853",
  "identifier": "karlsruher-sf-1853",
  "category": "verein",
  "awards": 5,
  "members": 200,
  "u25": 112,
  "female": 53,
  "avg_age": 33,
  "avg_rating": 1571,
  "coordinates": [
    [ 8.380872, 48.98837 ],
    [ 8.414175, 49.002422 ],
    [ 8.39314, 49.01481 ],
    [ 8.37892, 48.99875 ]
  ]
}
```
npm package: @schacker/easy-config-mock
Description: easy mock data with easy config, support customize middleware
Author: schacker
Latest version: 1.1.0

# easy-config-mock
[中文readme](https://github.com/nwa2018/easy-config-mock/blob/master/README-ZH.md)

easy mock data with easy config, `support customize middleware`. And it's easy integrated to your cli or workflow, what you have to do is just to `write some config`, and it can be `reload automatic`

> you can see a demo in the demo directory, please update your node to the 8.x version to run the demo

### install
--------
```
npm i easy-config-mock
or
yarn add easy-config-mock
```

### use
--------
``` javascript
const path = require('path')
const easyConfigMock = require('easy-config-mock')

new easyConfigMock({
  // just pass config file path to easyConfigMock, the server will watch this file and reload dynamic
  path: path.resolve(__dirname, 'xxxx.js')
})
```
`the config file example:`
``` javascript
// xxxx.js
module.exports = {
  // the common options is not neccessary, the default config is at bellow
  common: {
    // mock server default port, you can change the port, if the port is used, it will be changed automatic
    port: 8018,
    // maybe you want to see the ajax loading effect, you can set the request delay
    timeout: 500,
    // maybe you want to see what happen when the request fail, you can set the rate to 0, rate range between 0~1, mean the success rate
    rate: 1,
    // set false to stop the mock server
    mock: true
  },
  // api...
  '/pkApi/getList': {
    code: 0,
    'data|5': [{
      'uid|1000-99999': 999,
      'name': '@cname'
    }],
    result: true
  },
  '/pkApi/getPerson': {
    code: 0,
    'data|5': [{
      'name': '@cname'
    }],
    result: true
  },
  '/pkApi/getOther': {
    code: 0,
    'data|5': [{
      'name': '@cname'
    }],
    result: true
  }
}
```
open `http://127.0.0.1:8018/pkApi/getPerson` to see the mock data

### Q&A
--------
##### 1 how to mock jsonp
just pass the `callback` param in the request url
##### 2 how to mock data
you can reference the [mock rule](http://mockjs.com/examples.html)
##### 3 how to suit complex situation, I want to customize the response
please see the below demo, `api` can be object and can be function too, the function is a standard express middleware, you can write your logic, and `don't forget to mount your response in req.myData`
``` javascript
module.exports = {
  ...
  ['/pkApi/getOther'] (req, res, next) {
    const id = req.query.id
    req.myData = {   // this is important! mount your response in req.myData
      0: {
        code: 0,
        'test|1-100': 100
      },
      1: {
        code: 1,
        'number|+1': 202
      },
      2:{
        code: 2,
        'name': '@cname'
      },
      ...
    }[id]
    next()  // don't forget to call next in the last
  }
  ...
}
```
you can obtain the param in `req.query` in `get` request, and you can obtain the param in `req.body` in `post` request

### issues
-----------
feel free to open an issue when you encounter problems, [issue list](https://github.com/nwa2018/easy-config-mock/issues)
npm package: @schacker/hpack-cli
Description: > hpack-cli支持生成种子项目，开发，与输出生产环境的代码
Author: 1039407128lgx@gmail.com
Latest version: 0.2.0

# hpack-cli

> `hpack-cli`支持生成(vue or react or react-ts or react-redux or react-ts-redux)模板项目，开发，与输出生产环境的代码

### 安装

```s
npm i @schacker/hpack-cli -g
or
yarn global add @schacker/hpack-cli
```

> window平台请使用管理员权限安装，mac平台请在命令前面加上sudo

如果你不想全局安装的话

```s
git clone git@github.com:schacker/hpack-cli.git
cd hpack-cli
npm i / yarn
npm link
```

安装过程中如果报`fsevents`模块相关错误，请重新安装即可~

### 使用

```s
hpack -v  输出版本号
hpack     命令集
hpack c   检查版本
hpack u   版本升级
hpack i   生成种子文件
hpack d   开发
hpack b   构建
```

### 特性

- `hpack-cli` 内置了 `axios`, `jsonp`, `ramda`, `jquery`,无需二次安装
- 支持 `es6` 语法，支持 `async`, `await`, 支持装饰器
- `eslint` 采用 `standard` 规范
- 支持 `pug` 语法，`stylus`, `scss`
- 生产环境图片会自动压缩
- 支持单页应用，多页应用，支持项目集结构
- 支持少量的配置项
- 生产环境支持代码分割，懒加载，打哈希串
- 支持打包多个环境，主要是为了fix按需加载使用 `publicPath`

  -如使用 `ENVIRONMENT=test hpack b`，则打包配置会读取`webpack/webpack.test.js`配置，如果相应环境没做配置，则使用默认的 `/` 路径
  
  -如使用 `ENVIRONMENT=production hpack b`，则打包配置会读取`webpack/webpack.prod.js`配置，如果相应环境没做配置，则使用默认的 `/` 路径

  -打包后会在指定路径默认（`dist`）生成打包文件及文件信息，`cdnResource.json`,`cdnResource.ini`

### 目录结构

```s
+ react-project
+   src
-     index.js
    index.art       // 每一个xxx.art对应src目录的xxx.js，开发多页应用只需要增加这两个文件
    mock.config.js  // 必须：mock服务的配置文件
    config.js       // 必须：配置文件
```

### 开发

先生成种子文件，再开发

```s
hpack i
cd projectName
npm i
hpack d
```