open-index/open-npm huggingface dataset:
npm package: @sbizeul/fp-flow
Description: Collection of algebraic data types to use with Flow
Author: Sebastien Bizeul - seb.bizeul@gmail.com
Latest version: 0.6.0

# FP-FLOW [![Build Status](https://travis-ci.com/seb-bizeul/fp-flow.svg?branch=master)](https://travis-ci.com/seb-bizeul/fp-flow) 

### Install
    npm i -S @sbizeul/fp-flow

or

    yarn add @sbizeul/fp-flow

### Build
    yarn build

### Test
    yarn test

### Documentation
* [API Reference](https://github.com/seb-bizeul/fp-flow/wiki)
npm package: @sbj42/maze-generator
Description: An infrastructure for generating mazes
Author: James Clark
Latest version: 2.0.6

# maze-generator
A javascript maze generator

This library can be used to generate mazes using various algorithms.

Installation:

```
npm install --save-dev @sbj42/maze-generator
```

Don't forget to also choose a maze algorithm and install the plugin for that:

```
npm install --save-dev @sbj42/maze-generator-backtrack
```

Usage:

```
var mazeGen = require('@sbj42/maze-generator');

// generate a 20x20 maze
var maze = mazeGen.generate(20, 20, {
    generator: '@sbj42/maze-generator-backtrack'
});

// get the north-east corner cell of the maze
var cell = maze.cell(0, 0);
```

## API

`mazeGen.generate(width, height, options)`

The `generate()` function takes a width and a height, and returns a new maze object.  The (optional) `options` argument
can be used for additional settings:
* `options.random`: (optional) A random number generator, as a function that returns a number between 0 (inclusive) and
1 (exclusive).  The default random number generator is `Math.random`.
* `options.generator`: (optional) A maze-generator plugin, as a package name  The default plugin is
`@sbj42/maze-generator-backtrack` (though you'll need to make sure that's installed to use it).
* `options.mask`: (optional) A `GridMask`, indicating the cells the maze can use.  Any cell marked `false` in the mask
will not be used in the maze.  Some maze algorithms may not support this option.  The mask should be a single connected
region, if it isn't then the resulting maze may only fill one region.  For information about the `GridMask` API,
see the `@sbj42/maze-generator-core` package.

`maze.width()` / `maze.height()`

Return the width and height of the maze.

`maze.cell(x, y)`

Returns a cell object for the cell at the given position.

`cell.north()` / `cell.east()` / `cell.south()` / `cell.west()`

These boolean properties indicate whether the cell has a passage in each of the cardinal directions.  If the property
is `true`, then there is a passage in that direction.  `false` indicates a wall.

`mazeGen.GridMask(width, height, options)`

For information about the `GridMask` API, see the `@sbj42/maze-generator-core` package.

## Generator algorithms

Multiple generator algorithms can be used, each with different characteristics.  Here are some examples, with some
information about each, as measured generating a bunch of 100x100 mazes: 

| Algorithm                       | Relative Speed | Dead Ends | Branches | Avg. Dead End Length | Avg. Straight Run Length |
| ------------------------------- | --------------:| ---------:| --------:| --------------------:| ------------------------:|
| @sbj42/maze-generator-backtrack |           100% |     10.0% |     9.9% |                  2.1 |                      1.7 |
| @sbj42/maze-generator-prim      |            58% |     35.6% |    29.4% |                  1.6 |                      2.1 |
| @sbj42/maze-generator-kruskal   |            50% |     30.6% |    26.5% |                  1.7 |                      1.9 |
npm package: @sbj42/maze-generator-backtrack
Description: A recursive-backtracking maze generator algorithm
Author: James Clark
Latest version: 0.1.6

# maze-generator-backtrack
A recursive-backtracking maze generator algorithm

This is a plugin for the `sbj42/maze-generator` package.

Recursive-backtracking is like a randomized depth-first search of the
grid.  A random passage is dug from a random starting location, making
sure that the passage doesn't intersect itself.  At some point it
becomes impossible for this initial passage to make any more progress.
Then we travel back along the passage until we find a cell where we can
create a branch.  That branch is then extended randomly until it can no
longer proceed.  This process repeats until all cells have been connected
to the maze.

Recursive-backtracking tends to generate long, winding passages,
with few dead-ends.

```
___________________________________________________
| | ___________ _____ | ___________ _ __|__ | _ _ |
| __|________ | | | __| | _______ | | | ____| | |_|
| |__ ___ | __| | | | | |_| ______| | | | __| |__ |
|_____| | | _ | |_____|____ | ___ | | | | ______| |
|____ | __| | | | _______ | | |_____|_| |_____| _ |
| ___ | |___| | | | ___ |___| | ________| ______| |
|__ |_| | _ | |___|__ | _ | __|______ | __| _ __| |
| _ | __| |______ | __| |_|__ _ | _ | |__ |_| | __|
| |_|__ |__ | __| |___|__ _ | |_| | |_____| __|__ |
| | ____| __| _ |______ | |_|_____| _____ | | _ | |
| | |__ _ | __|____ _ |__ | _____ |____ | __| |___|
| |__ | | |____ | __|_| __|____ | | ____| | __|__ |
| __| |_| | __| |____ | |____ | |___|_____|______ |
| | __| __| ____| ____|____ | |______ | _____ __| |
|_______|_______|___________________|_______|_____|
```
npm package: @sbj42/maze-generator-dev
Description: Development support library for maze-generator plugins
Author: James Clark
Latest version: 0.1.8

# maze-generator-dev
Development support library for maze-generator plugins

This library supplies useful functions for developing plugins for the
[@sbj42/maze-generator](https://www.npmjs.com/package/@sbj42/maze-generator)
library.

## testAlgorithm

`testAlgorithm(algorithmName, algorithmFunc, options)`

Call this to run a standard set of tests on the algorithm.

## benchmarkAlgorithm

`benchmarkAlgorithm(algorithmName, algorithmFunc, options)`

Call this to run a standard set of performance benchmarks on the algorithm.

## cliDemoAlgorithm

`cliDemoAlgorithm(algorithmName, algorithmFunc, width, height, options)`

Call this from a command-line program, to print a sample maze for the algorithm.

## webDemoAlgorithm

`webDemoAlgorithm(algorithmName, algorithmModulePath, outPath)`

Call this to generate a static web page that demonstrates the algorithm.

## measureAlgorithm

`measureAlgorithm(algorithmName, algorithmModulePath)`

Call this to measure the characteristics of mazes generated by the algorithm.
npm package: @sbj42/maze-generator-kruskal
Description: A maze generator using a randomized Kruskal's algorithm
Author: James Clark
Latest version: 0.1.2

# maze-generator-kruskal
A maze generator using a randomized Kruskal's algorithm

This is a plugin for the `sbj42/maze-generator` package.

Kruskal's algorithm is a method of generating a "minimum spanning tree"
of an arbitrary graph.  This adapts naturally to generating mazes,
since every perfect maze is also a spanning tree.  For each wall, in
random order, we turn the wall into a passage if doing so does not
generate a loop.  That's it.  

```
___________________________________________________
|__ __|__ | | ___ | _______ __| | __________| | __|
| _ | ______| |__ _ | _ _ | ___ ____| __| _ ___ _ |
| |___|____ ___ |_|_|_| | | _ | ___ |_____|_|___| |
| | | ___ | | |____ ____| |_| |_| __|__ __| | ___ |
| _ __|__ |_| _ | | __|__ | |_| |_| |__ | ___ | | |
| |_|__ | |___|__ | _ __|__ | |__ | ___ _ | | | | |
|_| _ |____ ___ _ __| _ | |___| _ |__ | |_|____ | |
| __| | | __|___| |___| | ___ __|_| |_| |__ _ _ |_|
|__ |__ | ___ __| |__ __| __|_| _ ______|___| | | |
| ___ |__ _ |_| |_| | | ____|___|_| |__ | __| | | |
| | | | | |__ | _ |__ ___ ___ ___ ___ _ | ___ | __|
|___|_| __|__ | |_| ____| | __| _ | | | |_| __|___|
|__ _____ __|__ |__ _ | |_|_|___| __|_|____ ___ | |
| |_| _____ | |___| |_|__ __|__ _ |__ __| _ |__ __|
|_________|_______|_|___________|_______|_|_|_____|
```
npm package: @sbj42/maze-generator-prim
Description: A maze generator using a randomized Prim's algorithm
Author: James Clark
Latest version: 0.1.6

# maze-generator-prim
A maze generator using a randomized Prim's algorithm

This is a plugin for the `sbj42/maze-generator` package.

Prim's algorithm is a method of generating a "minimum spanning tree"
of an arbitrary graph.  This adapts naturally to generating mazes,
since every perfect maze is also a spanning tree.  The walls in the
maze are given equal weight, so we replace the part of Prim's
algorithm that finds the minimum-weight edge with code that simply
chooses a random edge.

Basically, this algorithm works by digging multiple random passages
at a time, randomly deciding which passage to work on at each step.
Compared to the 'recursive-backtracking' algorithm, this generator
tends to have more, shorter dead ends.

```
___________________________________________________
|__ | |__ | | _ _ _ | __| ____| | ____| ______| _ |
| |__ | | ____| |_|______ |____ ___ ___ | _____ |_|
|____ |___| | |_| _ ____| __|___| _ __|_| ____|_| |
|__ _________ |___| | | | _ | | |_| | | ____| | __|
| |_|______ ___ _ |__ __|_| | | | | ___ ______| | |
| | |__ |__ | | |____ __|__ __|__ | __| ___ | | __|
|________ |_| __| _ |____ _ | | | _ | |___| ___ | |
| __|____ ____|___| | __| |__ ___ |___| __| |__ _ |
| __| ___ | __|____ __| |_|__ |__ _ ____| | __|_| |
| ____|___| ___ | | ___ _ _ _ |__ |_| ___ |_|__ __|
| |__ |____ | |__ |_|__ | | |___| _ _ __|__ |____ |
|___| ___ |_|__ _____ __| |_| _ | |_|_____| ____| |
|__ |_|__ _ _ _ __| ____| |___| _ _ ____| |_| __| |
|____ _ _ | |_| __|_|____ | ___ | | __| | ____| |_|
|_____|_|_|___|___|_______|_|___|_|_______________|
```
npm package: @sbj42/word-search-generator
Description: A program to generate word search puzzles
Author: James Clark
Latest version: 0.1.2

# word-search-generator
A word search generator

## usage

```
var generator = require('@sbj42/word-search-generator');
var puzzle = generator();
console.info(puzzle.toString());
console.info(puzzle.words.join(','));
```

That might print:

```
H T E S A D A N W O
A O W O R T R U N K
R E A D I O M P I G
D T O W D L Y D A M
L G I S E D H C A E
Y N O N D R R O C K
D C U D U A I Y N L
K T A T O D Y C E O
J U D G E O O T H U
E H T O B P R G W D

add,army,both,day,dog,door,dry,each,god,hardly,judge,let,loud,
mad,old,own,pet,pig,read,rich,ride,rock,row,sad,set,sock,the,
toe,trunk,tune,unit,when,win,wind
```

# options

The generator function takes an optional options object, with these options:

`diagonals` (boolean)

Defaults to `true`.  Determines whether words can be placed diagonally on
the puzzle.

`width` and `height` (integer)

Defaults to 10x10.  Sets the size of the puzzle.

`minLength` and `maxLength` (integer)

Useful for making sure the words aren't too short or too long.  The default
for `minLength` is 3, and for `maxLength` is undefined. 

`words` (array of strings)

Words will be chosen randomly from this list.  If this is not provided, it
uses a built-in set of around 2,000 words.

# puzzle api

The object returned from the generator function has the following properties:

`width` and `height` (integer)

The size of the puzzle.

`grid` (array of string)

The letters in the puzzle.  For row R and column C, the letter can be found at
`grid[R * width + C]`.

`words` (array of string)

The words placed in the puzzle, in alphabetical order.

`get(C, R)`

A helper function to fetch the letter at row R and column C.

`toString()`

Prints the puzzle to a string, for testing or command-line output.
npm package: @sbjohansen/id-generator
Description: Package provides simple functionality for generating random IDs.
Author: SBJohansen
Latest version: 1.0.3

## Random ID generator module

Package provides simple functionality for generating random IDs.

## Installation

npm add @sbjohansen/id-generator

## License

MIT License

## Usage

### Import package:

const randomID = require('@sbjohansen/id-generator');

### Call function

randomID(number)
npm package: @sbmdkl/nepali-date-converter
Description: A javascript package to convert nepali date BS (Bikram Sambat) to AD and vice-versa, calcuate age from nepali date (BS)
Author: Shubham Dhakal
Latest version: 2.0.4

# @sbmdkl/nepali-date-converter

[![NPM](https://img.shields.io/npm/v/@sbmdkl/nepali-date-converter.svg)](https://www.npmjs.com/package/@sbmdkl/nepali-date-converter) [![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)

A javascript package to convert nepali date BS (Bikram Sambat) to AD and vice-versa. Also include a feature to calculate age in nepali date.
<a href="https://codesandbox.io/p/sandbox/sbmdkl-dateconverter-yqcrg5?file=/src/index.mjs">Demo</a>.

## Installation

```bash
npm install @sbmdkl/nepali-date-converter
```

## Usage

```jsx
const { adToBs, bsToAd, calculateAge } = require('@sbmdkl/nepali-date-converter');
try {
	const bsDate = adToBs('2078-03-05');
	console.log(bsDate);
	// to calculate age
	const myAge = calculateAge('2070-10-10');
	console.log(myAge);
} catch (e) {
	console.log(e.message);
}
```

## Available Methods

<pre>
adToBs('YYYY-MM-DD') - convert AD to BS date
bsToAd('YYYY-MM-DD') - convert BS to AD date
calculateAge('YYYY-MM-DD') - calculate age from BS date.
</pre>

## dateFormat

Format the date to provide various output based on format string

<pre>
YYYY - 4 digit of year (2078)
MM   - month number with 0 padding - (01-12)
DD   - Day of Month with zero padding (01-32)
</pre>

## Date Range

> Date convert will works between these Date Range:

Date Range for English Date : 1921 AD to 2040 AD

Date Range for Nepali Date : 1978 BS to 2099 BS

## License

MIT © [Shubham Dhakal](https://github.com/sbmdkl)
npm package: @sbnc/expect-type-extensions
Description: Additional type testing methods for the `expect-type` test suite.
Author: Bence Szalai
Latest version: 1.0.0-rc.0

# Expect Type Extensions
This package provides additional type testing methods for the [`expect-type`](https://github.com/mmkal/expect-type) compile-time test suite for types.

## Goal

Sometimes, we want to test whether two types can be used interchangeably, i.e., ensure that while they may not be equal, they can be assigned to each other.

For example:
```typescript
type Foo = { a: string, b: number }
type Bar = { a: string } & { b: number }
```

In practice, we can assign anything of type `Foo` to anything of type `Bar` and vice versa. So, from a practical point of view, these types are compatible. We naturally want to test for this kind of relationship between types.

## Challenge

While `expect-type` is a great utility, it is a bit suboptimal for this particular case. We cannot use a single `toEqualTypeOf`, as both of these would result in an error:
```typescript
expectTypeOf<Foo>().toEqualTypeOf<Bar>() // error, but we want a pass
expectTypeOf<Bar>().toEqualTypeOf<Foo>() // error, but we want a pass
```

This means we would need to resort to two `toMatchTypeOf` tests:
```typescript
expectTypeOf<Foo>().toMatchTypeOf<Bar>()
expectTypeOf<Bar>().toMatchTypeOf<Foo>()
```

We need both lines because in the following case, only one of them shows the issue:
```typescript
type Baz = { a: string, b: number, c: boolean }

expectTypeOf<Baz>().toMatchTypeOf<Foo>() // seems okay
expectTypeOf<Foo>().toMatchTypeOf<Baz>() // but this line shows the issue with Baz being incompatible
```

However, it can be a bit hard to read and maintain: always writing double test lines for this kind of scenario. 

## Solution

This utility provides a single `.toMatchEachOther<>()` method which can be used to test for this kind of relationship between types.

With this in place, we can now write what took us 4 tests before in only 2 lines:
```typescript
expectTypeOf<Foo>().toMatchEachOther<Bar>() // pass
expectTypeOf<Foo>().toMatchEachOther<Baz>() // error, Baz is not compatible
```

If the second one is the expected behaviour, we can use the `.not.toMatchEachOther<>()` method instead:
```typescript
expectTypeOf<Foo>().not.toMatchEachOther<Baz>() // pass
```

## Usage

### Installation

Install using npm or your choice of package manager, e.g.:

`npm install --save-dev @sbnc/expect-type-extensions`

### Importing

To use the new utilities, make sure to import this package along with `expect-type`, e.g.:

```typescript
import { expectTypeOf } from 'expect-type'
import '@sbnc/expect-type-extensions'
```

Note: There is no need for a `{...} from` part in the import statement.

***

Bence Szalai - https://sbnc.eu/
npm package: @sbnpmiamldw/ui-library
Description: React cpmponents library
Author: halcyon_landawang
Latest version: 0.1.2

# Getting Started with Create React App

This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app).

## Available Scripts

In the project directory, you can run:

### `npm start`

Runs the app in the development mode.\
Open [http://localhost:3000](http://localhost:3000) to view it in the browser.

The page will reload if you make edits.\
You will also see any lint errors in the console.

### `npm test`

Launches the test runner in the interactive watch mode.\
See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.

### `npm run build`

Builds the app for production to the `build` folder.\
It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.\
Your app is ready to be deployed!

See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.

### `npm run eject`

**Note: this is a one-way operation. Once you `eject`, you can’t go back!**

If you aren’t satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project.

Instead, it will copy all the configuration files and the transitive dependencies (webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you’re on your own.

You don’t have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it.

## Learn More

You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).

To learn React, check out the [React documentation](https://reactjs.org/).