open-index/open-npm huggingface dataset:
npm package: 1-2and3
Description: Utility to join array element with `,` and last element with `and`
Author: Ninad Mahajan
Latest version: 1.1.0

## 1, 2, and 3
---
![GitHub Workflow Status (with event)](https://img.shields.io/github/actions/workflow/status/Ninad89/1-2and3/node.js.yml)
![Codecov](https://img.shields.io/codecov/c/gh/Ninad89/1-2and3)
![npm](https://img.shields.io/npm/dt/1-2and3)
![NPM](https://img.shields.io/npm/l/1-2and3)

[![NPM](https://nodei.co/npm/1-2and3.png)](https://nodei.co/npm/1-2and3/)


This utility joins array elements with `, ` and last element with `and`

Suppose if you want to join all elements of string array, but not just with the `,` . 

This utility is here to just solve that tiny problem.

### Let's see how to use.
```
import join from '1-2and3'

join(['1', '2', '3', '4']) // 1, 2, 3 and 4
join(['1', '2']) // 1 and 2
join(['1']) // 1
join([]) //
join(['1', '2', '3', '4'], ', ', '&') // 1, 2, 3 & 4
```
> Element separator can be customized by passing second parameter to function.

> Last element separator also can be customized by passing third argument to function


### License
MIT
npm package: 1-click-bom
Description: Parse and write 1-click-BOM data.
Author: Kaspar Emanuel
Latest version: 1.3.1

# The 1-click-BOM NPM Library

A library for dealing with bill of material data for use with the 
[1clickBOM extension](https://github.com/monostable/1clickBOM).

## Getting started

- [Set up NodeJS](https://nodejs.org/en/download/)
- Then:

```
git clone https://github.com/monostable/npm-1-click-bom
cd npm-1click-bom
npm install
npm run build
npm run test
```

## License

This project is MIT licensed
npm package: 1-line-opening-hours
Description: Simple parser for OpenStreetMap `opening_hours`
Author: SnowPact
Latest version: 0.3.2

# 1-line-opening-hours

Get rid of heavy responses from API when using simple opening hours, by using the OpenStreetMap `opening_hours` format.

This was first forked from [wbkd](https://github.com/wbkd/simple-opening-hours). The project then aimed to be bigger, so a lot of code has been rewrote and new features added.

It only supports the human readable parts and not [this complete crazy overengineered specification](https://wiki.openstreetmap.org/wiki/Key:opening_hours/specification).

## Supported opening_hours examples

* `Mo-Sa 06:00-22:00`
* `Mo-Fr 08:00-18:00; Sa 10:00-14:00`
* `Mo-Fr 08:00-18:00; Sa,Su 10:00-20:00`
* `Mo-Fr 08:00-12:00, We 14:00-18:00`
* `Mo-Fr 08:00-12:00, 14:00-18:00`
* `Mo-Fr 08:00+`
* `Mo-Fr 08:00-01:00`
* `Mo-Fr 08:00-18:00; We off`
* `24/7`


## Getting started

### Install
```
npm install 1-line-opening-hours --save
yarn add 1-line-opening-hours
```
### Usage
```javascript
const openingHours = new OpeningHours('Mo-Sa 06:00-22:00');

console.log('Is this open now?', openingHours.isOpenNow());
console.log('Is this open on 2016-10-01 18:00?', openingHours.isOpenOn(new Date('2016-10-01 18:00')));
console.table(openingHours.getTable());
```	

### API

| Method | Description | Return value |
|--------|-------------|--------------|
| `isOpenNow()` | Check whether the establishment is open now based on the provided opening hour | `true` or `false` 
| `isOpenOn(date: Date)` | Same than above for any date | `true` or `false` 
| `getTable()` | Get an array of each day and the corresponding opening time | `{ su: [], mo: ['06:00-22:00'] ... }`
| `getFullStatusOfToday()` | Send more information about the current opening status, the next day that it will be opened... | `{ open: false openUntil: null, nextReopening: { hour: '11:00', day: 'tu', opensInDay: 0 }`
| `getFullStatusOfDay(date: Date)` | Same than above for any date | `{ open: false openUntil: null, nextReopening: { hour: '11:00', day: 'tu', opensInDay: 0 }`
npm package: 1-liners-cli
Description: CLI for copying code from "1-liners" project.
Author: Lochlan Bunn
Latest version: 1.0.3

# 1-liners cli

<p align="center">
  <img alt="Screenshot of the CLI starting" src="https://gist.githubusercontent.com/loklaan/41f5408d99832b9afc011abdb5c0b509/raw/c651c391fb44d6efcf6b487b2fb22c26ca829d17/1-liners-cli.png" width="700px" />
</p>

<p align="center">
  Copy common util functions to clipboard, courtesy of <a href="https://github.com/1-liners/1-liners"><strong><code>1-liners</code></strong></a>
</p>

## Quick Start

```bash
$ npx 1-liners-cli
```

## Keep It Around

```bash
$ npm install -g 1-liners-cli      # Install globally
$ 1-liners                         # Show a list of 1-liners
$ 1-liners isFunction              # Copy a function immediately
$ 1-liners isFunction --print      # Print to stdout instead of copy to clipboard
```

## Legal

### license

The MIT License (MIT)  
Copyright © Lochlan Bunn

### attribution

"1-liners" source licensed MIT from [1-liners/1-liners](https://github.com/1-liners/1-liners) via [stoeffel](https://github.com/stoeffel).
npm package: 1-out-of-n
Description: 1-out-of-n oblivious transfer
Author: Wyatt Howe
Latest version: 0.4.3

# 1-out-of-n
1-out-of-n oblivious transfer protocol in JavaScript

## Protocol

To create 1-out-of-N, we use log2(N) 1-out-of-2 oblivious transfers of random bits to create log2(N) random strings.  Each secret is masked with one of these strings (by XOR) and the receiving party picks one after which the sender reveals all the masked secrets.

We build 1-out-of-N OT by composing random 1-out-of-N and multiple 1-out-of-2 oracles.  This is the same protocol as described in [*Oblivious Transfer and Polynomial Evaluation* pp. 247-248](https://doi.org/10.1145%2F301250.301312)<!-- [pdf](https://books c.xyz/dl/28462147/d44b14?openInBrowser) -->.

<!-- cite @inproceedings{Naor_1999,
	doi = {10.1145/301250.301312},
	url = {https://doi.org/10.1145%2F301250.301312},
	year = 1999,
	publisher = {{ACM} Press},
	author = {Moni Naor and Benny Pinkas},
	title = {Oblivious transfer and polynomial evaluation},
	booktitle = {Proceedings of the thirty-first annual {ACM} symposium on Theory of computing  - {STOC} {\textquotesingle}99}
} -->

## Project layout

```
├─ index.js           Module entry point (include this or use npm)
├─ lib/               Library source
│  ├─ ot.js             Oblivious transfer protocols
│  ├─ util.js           Bitwise helpers
│  └─ crypto.js         Crypto primitives
└─ demo/              Example demos
   ├─ io-example.js     Input-output communication for the demos
   ├─ io-template.js    IO methods template
   ├─ strings/          Strings demo
   │  ├─ example.js       OT choosing from strings
   │  └─ ascii.js         ASCII helpers to convert inputs to Uint8Array
   └─ numbers/          Numbers demo
      └─ example.js       OT choosing from numbers
```

## Installation

You may also install this module from [npm](https://www.npmjs.com/package/1-out-of-n/v/0.3.0).

```shell
npm install 1-out-of-n
```

## Calling the API

The process generally works as follows:

```javascript
// Each party includes the 1-out-of-n module with IO:
const OT = require('1-out-of-n')(IO);

// 1-out-of-3
const N = 3;

// The sender calls send and provides its secrets:
OT.send([77, 66, 88], N);

// The receiver calls receive with its selection out of N:
OT.receive(2, N).then(console.log.bind(null, 'Secret #2 is:'));

// Result:
66
```

Note that the latest version expects to get an array of Uint8Array as inputs, so if you are working with numbers larger than 8 bits, it is strongly recommended to use the Uint8Array byte array type to represent your number choices.  Please read [strings/example.js](https://github.com/wyatt-howe/1-out-of-n/blob/master/demo/strings/example.js) for a more detailed example or run it with `node demo/*/example.js`.

## Test suite

The example demos in `demo/numbers/example.js` and `demo/strings/example.js` test both a basic, and slightly more advanced usage of the library.  You may run them individually, or use the pre-configured test script by running `npm test`.  All versions and releases have tests passing.

## Code linting

Please run `npm run-script lint-fix` before submitting a pull request.