open-index/open-npm huggingface dataset:
npm package: @hazae41/arrays
Description: Utilities to deal with arrays
Author: hazae41
Latest version: 2.0.3

# Arrays

Utilities to deal with arrays

```bash
npm i @hazae41/arrays
```

[**Node Package 📦**](https://www.npmjs.com/package/@hazae41/arrays)

## Features

### Current features
- 100% TypeScript and ESM
- No external dependency
- Unit-tested and benchmarked
- Get the last value
- Get a random value using Math's PRNG
- Get a random value using WebCrypto's CSPRNG
- Sized types `ArrayLike<T,N>` and `Array<T,N>`

## Usage

### Arrays.last

Get the last value

```tsx
import { Arrays } from "@hazae41/arrays"

const value = Arrays.getLastOrNull([1, 2, 3, 4, 5])
```

### Arrays.random

Get a random value using Math's PRNG

```tsx
import { Arrays } from "@hazae41/arrays"

const value = Arrays.getRandomOrNull([1, 2, 3, 4, 5])
```

### Arrays.cryptoRandom

Get a random value using WebCrypto's CSPRNG

```tsx
import { Arrays } from "@hazae41/arrays"

const value = Arrays.getCryptoRandomOrNull([1, 2, 3, 4, 5])
```
npm package: @hazae41/asn1
Description: Zero-copy ASN.1 <=> DER encoding for the web
Author: hazae41
Latest version: 1.3.35

<div align="center">
<img src="https://user-images.githubusercontent.com/4405263/219944360-d138f86e-5517-4859-a532-1a6e45579074.png" />
</div>

```bash
npm i @hazae41/asn1
```

[**Node Package 📦**](https://www.npmjs.com/package/@hazae41/asn1)

## Features

### Current features
- 100% TypeScript and ESM
- No external dependency
- Rust-like patterns
- Zero-copy DER <=> ASN1 reading and writing
- Almost all universal triplets
- Implicit and explicit tagged types

### [Upcoming features](https://github.com/sponsors/hazae41)
- More string types
- More encodings

## Usage

```typescript
import { DER } from "@hazae41/asn1"

const input = new Uint8Array([0x01, 0x01, 0xFF])

const triplet = DER.tryFromBytes(input).unwrap() // Boolean

console.log(triplet.toString()) // "BOOLEAN true"

const output = DER.tryToBytes(triplet).unwrap() // Uint8Array([0x01, 0x01, 0xFF])
```
npm package: @hazae41/base16
Description: Base16 adapter for JS implementations
Author: hazae41
Latest version: 2.0.2

# Base16

Base16 adapter for JS implementations

```bash
npm i @hazae41/base16
```

[**Node Package 📦**](https://www.npmjs.com/package/@hazae41/base16)

## Features

### Current features
- 100% TypeScript and ESM
- No external dependencies
- Automatic implementation

## Usage

```tsx
const encoded: string = Base16.encodeOrThrow(new Uint8Array([1,2,3,4,5]))
```

```tsx
const decoded: Uint8Array = Base16.decodeOrThrow(encoded)
```