open-index/open-npm huggingface dataset:
npm package: @lcds/form-helper
Description: Javascript Utility library to ensure nicely filled form
Author: Kevin Vinhas
Latest version: 1.1.2

 <div align="center">
  <h2>Form Helper Javascript Library</h2>
  <blockquote>A tool to ensure the quality of your form data</blockquote>

<strong>This has been set thanks to a basic library boilerplate. For more robust info about the cool work, check out [js-library-boilerplate-basic](https://github.com/hodgef/js-library-boilerplate-basic).</strong>

</div>
npm package: @lcf.vs/abstract
Description: A simple base abstract class, in JavaScript, to extend with immutables & type forcing
Author: lcf.vs
Latest version: 2.0.4

# <a name="reference">Abstract</a>

A simple base abstract class to extend, with immutables & type forcing

## <a name="install">Install</a>

`npm i @lcf.vs/abstract`

## <a name="usage">Usage</a>

```js
import Abstract from '@lcf.vs/abstract'

class AbstractApplication extends Abstract {
  constructor (
    constructor = AbstractApplication,
    {router, renderer, server, ...rest},
    ...requirements
  ) {
    super(constructor, {renderer, router, server, ...rest}, ...[
      ...requirements, {
      renderer: Object,
      router: Object,
      server: Object
    }])
  }
}

class Application extends AbstractApplication {
  constructor (router, renderer, server, rest = {}) {
    super(AbstractApplication, {router, renderer, server, ...rest})
  }
}
```

## <a name="api">API</a>

```js
/**
* @param {Abstract=Abstract} constructor
* @param {Object=} immutables
* @param {...Object} requirements
*/
Abstract(constructor = Abstract, immutables = {}, ...requirements)
```

 * `constructor`: The current abstract constructor 
 * `immutables`: The immutable properties
 * `requirements`: The properties's constructors, to validate their types

## <a name="license">License</a>

[MIT](https://github.com/Lcfvs/content-handler/blob/master/licence.md)
npm package: @lcf.vs/collection-api
Description: A @lcf.vs/collection API
Author: Lcf.vs
Latest version: 1.0.5

# @lcf.vs/collection-api

[PRERELEASE] A `@lcf.vs/collection` API

## Examples
[`npm run example-root`](./example/root.js)
```json
{
  "collection": {
    "href": "https://api.localhost",
    "version": "1.0",
    "links": [
      {
        "href": "https://docs.localhost",
        "rel": "help"
      }
    ],
    "items": [
      {
        "data": [
          {
            "name": "name",
            "value": "accounts"
          }
        ],
        "href": "/accounts"
      }
    ]
  }
}
```

[`npm run example-account`](./example/account.js)
```json
{
  "collection": {
    "href": "/accounts/create",
    "version": "1.0",
    "links": [
      {
        "href": "/accounts",
        "rel": "collection"
      }
    ],
    "items": [
      {
        "data": [
          {
            "name": "id",
            "value": 1
          },
          {
            "name": "name",
            "value": "Lcf.vs"
          }
        ],
        "href": "/accounts/1",
        "links": [
          {
            "href": "https://github.com/Lcfvs",
            "rel": "github"
          }
        ]
      }
    ]
  }
}
```

[`npm run example-accounts`](./example/accounts.js)
```json
{
  "collection": {
    "href": "/accounts",
    "version": "1.0",
    "links": [
      {
        "href": "https://api.localhost",
        "rel": "collection"
      }
    ],
    "queries": [
      {
        "href": "/accounts/create",
        "prompt": "Create an account",
        "rel": "create",
        "data": [
          {
            "name": "name",
            "prompt": "Account name"
          }
        ],
        "links": [
          {
            "rel": "github",
            "prompt": "Account GitHub"
          }
        ]
      },
      {
        "href": "/accounts/search-by-name",
        "prompt": "Search an account by its name",
        "rel": "search",
        "data": [
          {
            "name": "name",
            "prompt": "Account name"
          }
        ]
      }
    ],
    "template": {
      "data": [
        {
          "name": "id",
          "prompt": "Account ID"
        },
        {
          "name": "name",
          "prompt": "Account name"
        }
      ],
      "links": [
        {
          "rel": "github",
          "prompt": "Account GitHub"
        }
      ]
    }
  }
}
```

[`npm run example-error`](./example/error.js)
```json
{
  "collection": {
    "href": "/accounts/create",
    "version": "1.0",
    "links": [
      {
        "href": "https://api.localhost",
        "rel": "collection"
      }
    ],
    "error": {
      "code": "INVALID_ACCOUNT",
      "message": "Invalid account",
      "details": [
        {
          "message": "Invalid account name",
          "name": "name"
        }
      ]
    }
  }
}
```
npm package: @lcf.vs/curryable
Description: An utility to make any function repeatedly curryable
Author: lcf.vs
Latest version: 1.0.4

# <a name="reference">curryable</a>

An utility to make any function repeatedly curryable

## <a name="install">Install</a>

`npm i @lcf.vs/curryable`

## <a name="usage">Usage</a>

### <a name="basic-example">Basic example</a>

```js
import curryable from '@lcf.vs/curryable'

const log = curryable((...values) => console.log(values), 0)

log(1, 2, 3) // [0, 1, 2, 3]
log.curry(1, 2, 3)(4, 5, 6) // [0, 1, 2, 3, 4, 5, 6]
log.curry(1, 2, 3).curry(4, 5, 6)(7, 8, 9) // [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
```

### <a name="real-world-example">Real world example</a>

```js
import path from 'path'
import curryable from '@lcf.vs/curryable'

const __filename = new URL(from.url).pathname
const resolve = curryable(path.resolve, __filename, '..')
// const __dirname = resolve()
const src = resolve.curry('src')
const html = src.curry('html')
const assets = src.curry('assets')
 
const paths = {
  index: html('index.html'),
  assets: [
    assets('js/index.js'),
    assets('css/style.css')
  ]
}
```

## <a name="api">API</a>

```js
/**
 * Returns a reduced function from `fn`, with a `.curry` method to repeat the
 * process on the new one
*  @function curryable
 * @param {Function} fn
 * @param {...*} args
 * @return {Function&Object}
 */
import curryable from '@lcf.vs/curryable'

function fn () {}

const args = []
const fn = curryable(fn)
const newFn = fn.curry(...args)
```

```js
/**
 * Returns a reduced function from `fn`
*  @function curry
 * @param {Function} fn
 * @param {...*} args
 * @return {Function}
 */
import {curry, isCurryable} from '@lcf.vs/curryable'

function fn () {}

const args = []
const newFn = curry(fn, ...args)
```

```js
/**
 * Checks if `fn` has the provided `.curry()` method
*  @function isCurryable
 * @param {Function} fn
 * @return {boolean}
 */
import {curryable, isCurryable} from '@lcf.vs/curryable'

function fn () {}

const args = []
const result = isCurryable(curryable(fn, ...args)) // true
```



## <a name="license">License</a>

[MIT](https://github.com/Lcfvs/curryable/blob/master/licence.md)
npm package: @lcf.vs/dom
Description: Some utility classes, as ES6 module, to easily the DOM, even in front/back
Author: lcf.vs
Latest version: 0.0.2

# <a name="reference">@lcf.vs/dom</a>

Some utility classes, as ES6 module, to easily the DOM, even in front/back

## <a name="install">Install</a>

`npm i @lcf.vs/dom`

## <a name="usage">Usage</a>

```js
import dom from '@lcf.vs/dom'

console.log(dom)
```

## <a name="apis">APIs</a>

[html.js](./html.md)
npm package: @lcf.vs/generics
Description: Some useful JS generics
Author: lcf.vs
Latest version: 1.0.0-alpha-107

# @lcf.vs/generics

**[ALPHA]** Some useful JS generics, using:
 - [knex](https://www.npmjs.com/package/knex)
 - [express](https://www.npmjs.com/package/express) (or any express-like router)


## Install

`npm i @lcf.vs/generics`


## Example

[@lcf.vs/generics-tests](https://github.com/Lcfvs/generics-tests)


## Test it

`npm test @lcf.vs/generics`


## License

[MIT](./LICENSE)
npm package: @lcf.vs/generics-tests
Description: @lcf.vs/generics tests repository
Author: lcf.vs
Latest version: 0.6.1

# @lcf.vs/generics-tests

[@lcf.vs/generics](https://github.com/Lcfvs/generics) tests repository


## Install

`git clone https://github.com/Lcfvs/generics-tests`

`cd generics-tests`

`npm i --save-dev`


## Building


### 1# Create your `knex` migrations

#### Example
[./migrations/{name}.js](./migrations/events.js)


### 2# Run your migrations

`npm run latest`


### 3# Describe your table & columns, based on [generics W3C parsers](https://github.com/Lcfvs/generics/tree/master/lib/validation/parsers/w3c)

**(values must be strings)**

#### Example
[./lib/entities/{name}/defs/table.js](./lib/entities/events/defs/table.js)


### 4# Create your hooks

#### Example
[./lib/entities/{name}/defs/hooks.js](./lib/entities/events/defs/hooks.js)


### 5# Create your routes

#### Example
[./lib/entities/{name}/defs/routes.js](./lib/entities/events/defs/routes.js)


### 6# Link them all to an entity module

#### Example
[./lib/entities/{name}/{name}.js](./lib/entities/events/events.js)


### 7# Link the entity module to the entities module

#### Example
[./lib/entities/entities.js](./lib/entities/entities.js)


### 8# Add your tests

#### Example
[./tests/test.js](./tests/test.js)


### 9# Test it

`npm test`


## License

[MIT](./LICENSE)
npm package: @lcf.vs/io
Description: Simplify your function input destructuring
Author: lcf.vs
Latest version: 1.1.2

# <a name="reference">io</a>

Simplify your function input destructuring

## <a name="install">Install</a>

`npm i @lcf.vs/io

## <a name="api">API</a>

```js
/**
* @param {Function} fn - the function to call
* @param {*} input - the function input (duplicated and sent as array)
* @param {...*} args - the extra arguments
*/
io(fn, input, ...args)
```
## <a name="usage">Usage</a>

### <a name="basic">Basic</a>

```js
import io from '@lcf.vs/io'

function defineC([{a, b}, input], c) {
  input.c = c
}

function defineD([{a, b, c}, input]) {
  input.d = a + b + c
}

function log([input]) {
  console.log(input)
}

const obj = {a: 1, b: 2}

io(defineC, obj, 3) // obj = {a: 1, b: 2, c: 3}
io(defineD, obj) // obj = {a: 1, b: 2, c: 3, d: 6}
io(log, obj) // {a: 1, b: 2, c: 3, d: 6}
```

### <a name="using-a-constructor">Using a constructor</a>

```js
import io from '@lcf.vs/io'

function Member([{members}], name) {
  this.name = name
  members[name] = this
}

const team = {
  members: {}
}

new io(Member, team, 'Lcf.vs')
console.log(team) // {members: {'Lcf.vs': {name: 'Lcf.vs'}}}
```

## <a name="license">License</a>

[MIT](https://github.com/Lcfvs/io/blob/master/licence.md)
npm package: @lcf.vs/mjs-path
Description: An utility to resolve some mjs/installed modules paths
Author: lcf.vs
Latest version: 1.0.1

# <a name="reference">mjs-path</a>

An utility to resolve some mjs/installed modules paths

## <a name="install">Install</a>

`npm i @lcf.vs/mjs-path`

## <a name="usage">Usage</a>

```js
import meta from '@lcf.vs/mjs-path'
import installed from '@lcf.vs/mjs-path/installed'

const __filename = meta.filename(import.meta)
const __dirname = meta.resolve(import.meta)
const submodule = meta.resolve(import.meta, './submodule.mjs')
// Or submodule = meta.resolve.curry(import.meta)( './submodule.mjs')

const mjsPathFilename = installed.filename('@lcf.vs/mjs-path')
const mjsPathDirname = installed.resolve('@lcf.vs/mjs-path')
const mjsPathSubmodule = installed.resolve('@lcf.vs/mjs-path', './installed.mjs')
// Or mjsPathSubmodule = installed.resolve.curry('@lcf.vs/mjs-path')( './installed.mjs')
```

## <a name="api">API</a>

### <a name="imported-modules">Imported modules</a>
```js
import meta from '@lcf.vs/mjs-path'

/**
* A function to get the filename from an import.meta
* @param {string} meta
* @return {string}
*/
const filename = meta.filename(import.meta)

/**
* A curryable function to resolve some paths from an import.meta directory
* @param {string} meta
* @param {...string} [to]
* @return {string}
*/
const directory = meta.resolve(import.meta, ...to)
```

### <a name="installed-ornative-modules">Installed/native modules</a>
```js
import installed from '@lcf.vs/mjs-path/installed'

/**
* A function to get the filename from an installed/native module name
* @param {string} name
* @return {string}
*/
const filename = installed.filename(name)

/**
* A curryable function to resolve some paths from an installed/native module
*   directory
* @param {string} meta
* @param {...string} [to]
* @return {string}
*/
const directory = installed.resolve(name, ...to)
```

## <a name="license">License</a>

[MIT](https://github.com/Lcfvs/mjs-path/blob/master/licence.md)
npm package: @lcf.vs/object
Description: An utility to create an object and assign at once
Author: lcf.vs
Latest version: 1.0.2

# <a name="reference">object</a>

An utility to create an object and assign at once

## <a name="install">Install</a>

`npm i @lcf.vs/object`

## <a name="usage">Usage</a>

```js
import object from '@lcf.vs/object'

const empty = object()
const prototyped = object({prototyped: true})
const assigned = object(null, {assigned: true})
const together = object(prototyped, assigned, {together: true})

console.log(empty) // {}
console.log(prototyped.prototyped) // true
console.log(assigned.assigned) // true
console.log(together.prototyped && together.assigned && together.together) // true
```

## <a name="api">API</a>

```js
/**
 * Clones the prototype and assigns the extensions on it
 * @param {object|null} [prototype=null]
 * @param {...object} extensions
 * @return {object&(prototype|null)}
 */
import object from '@lcf.vs/object'

const obj = object(prototype || null, ...extensions)
```

## <a name="license">License</a>

[MIT](https://github.com/Lcfvs/object/blob/master/licence.md)