# ksp

> A simple framework for build your app more easiest !

Latest version **1.1.4** (published 2019-03-06) · MIT license · 0 weekly downloads

## Install

```sh
npm install ksp
pnpm add ksp
yarn add ksp
bun add ksp
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.1.4 |
| Published | 2019-03-06 |
| First published | 2019-03-03 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 7.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | dotjov |
| Maintainers | dotjov |
| Keywords | ksp, easy, build, app |

## Links

- npm: https://www.npmjs.com/package/ksp
- Repository: https://github.com/dotjov/ksp-typescript
- Homepage: https://github.com/dotjov/ksp-typescript#readme
- Issues: https://github.com/dotjov/ksp-typescript/issues
- npm.io page: https://npm.io/package/ksp

## Dependencies (1)

- [debug](https://npm.io/package/debug.md) ^4.1.1

## Alternatives

- [raw-loader](https://npm.io/package/raw-loader.md) — 4.3M weekly downloads
- [plop](https://npm.io/package/plop.md) — 1.4M weekly downloads
- [webpack-deadcode-plugin](https://npm.io/package/webpack-deadcode-plugin.md) — 80.3K weekly downloads
- [@storybook/preact-vite](https://npm.io/package/@storybook/preact-vite.md) — 54.2K weekly downloads
- [vite-plugin-transform](https://npm.io/package/vite-plugin-transform.md) — 2.4K weekly downloads

## Recent versions

- 1.1.4 (latest) — 2019-03-06
- 1.1.3 — 2019-03-06
- 1.1.2 — 2019-03-04
- 1.1.1 — 2019-03-04
- 1.1.0 — 2019-03-04
- 1.0.1 — 2019-03-03
- 1.0.0 — 2019-03-03

## README

# ksp

[![Build Status](https://travis-ci.org/dotjov/ksp.svg?branch=master)](https://travis-ci.org/dotjov/ksp)
[![codecov](https://codecov.io/gh/dotjov/ksp/branch/master/graph/badge.svg)](https://codecov.io/gh/dotjov/ksp)
[![npm version](https://img.shields.io/npm/v/ksp.svg)](https://www.npmjs.com/package/ksp)
[![npm bundle size (minified)](https://img.shields.io/bundlephobia/min/ksp.svg)](https://www.npmjs.com/package/ksp)

A simple framework for build your app more easiest !

**Active modules**

- [ksp-express](https://www.npmjs.com/package/ksp-express) (Create a express web site with ksp framework)

## Install

```sh
$ npm install ksp
```

## Usage

```js
const ksp = require('ksp')
const run = ksp.runKsp // or use ksp.runKsp() instead of create a const

ksp.createKsp('some thing', (message) => {
    console.log(message)
})

run('some thing', 'done!')
// => "done!"
```

More example can be found [here](https://github.com/dotjov/ksp/blob/master/examples/) (eg. callback function/promise/return)

## Methods

##### createKsp(name: string, run: Function): void

```js
ksp.createKsp('some thing', (callback) => {
    // eg. get user from db
    callback(user)
})
```

##### runKsp(name: string, ...args: any): any

```js
ksp.runKsp('some thing', (user) => {
    console.log(user.name)
})
```

##### use(module: any): void

```js
const kspExpress = require('ksp-express')
ksp.use(kspExpress())
```

## Test

```sh
$ git clone https://github.com/dotjov/ksp
$ npm install
$ npm run test
```

## Debug

Ksp support [debug](https://www.npmjs.com/package/debug), set `DEBUG = 'ksp'`. It will print when a ksp has been run or create and a module has been added

## License

MIT License

Copyright (c) 2019 dotjov

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

---
_Source: https://npm.io/package/ksp · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
