open-index/open-npm huggingface dataset:
npm package: @safelytyped/core-types
Description: Core safe types for Typescript
Latest version: 0.5.1

# Core Safe Types for TypeScript

## Introduction

This TypeScript library gives you a set of core safe types to build upon.

## Quick Start

```
# run this from your Terminal
npm install @safelytyped/core-types
```

```typescript
// add this import to your Typescript code
import { Value } from "@safelytyped/core-types"
```

__VS Code users:__ once you've added a single import anywhere in your project, you'll then be able to auto-import anything else that this library exports.

## Documentation

Here's a link to all the documentation about this project.

### Admin Paperwork

* [Our CHANGELOG](CHANGELOG.md)
* [Our software license](LICENSE.md)

### For Contributors

* [How to contribute](CONTRIBUTING.md)
* [Our Code of Conduct](CODE-OF-CONDUCT.md)
* [Our NPM scripts](./docs/v1/contributors/NPM-Scripts.md)

### Credits

* [Current Maintainers](MAINTAINERS.md)
* [All contributors to date](AUTHORS.md)

Follow us on [Twitter](https://twitter.com/SafelyTyped)!
npm package: @safelytyped/data-requirements
Description: A library for validating any data structures.
Latest version: 0.0.2

# Welcome To @safelytyped/data-requirements!

## Introduction

Data Requirements is a Typescript library. Use it to build type validators for anonymous objects in your libraries.

At the moment, this is very much an experimental library. I'm expecting it to change a lot before the v1.0 release.

## Quick Start

```
# run this from your Terminal
npm install @safelytyped/data-requirements
```

## Documentation

Looking for more detailed documentation? You'll find it under the [docs](./docs) folder.

* [Our CHANGELOG](CHANGELOG.md)
* [Our software license](LICENSE.md)
* [All contributors to date](AUTHORS.md)
npm package: @safelytyped/filepath
Description: A safe type for working with locations on local filesystems, for Typescript.
Latest version: 0.2.0

# Welcome To @safelytyped/filepath!

## Introduction

ADD YOUR INTRODUCTION HERE!!

## Quick Start

```
# run this from your Terminal
npm install @safelytyped/filepath
```

```typescript
// add this import to your Typescript code
import { Value } from "@safelytyped/filepath"
```

__VS Code users:__ once you've added a single import anywhere in your project, you'll then be able to auto-import anything else that this library exports.

## Documentation

Looking for more detailed documentation? You'll find it under the [docs](./docs) folder.

* [Our API](./docs/api/)
* [Our CHANGELOG](CHANGELOG.md)
* [Our software license](LICENSE.md)
* [All contributors to date](AUTHORS.md)
npm package: @safelytyped/ip-port
Description: Provides a safe type for an IP port, for Typescript
Latest version: 0.2.0

# Welcome To @safelytyped/ip-port!

## Introduction

This library provides a safe `IpPort` type, and supporting helper functions.

## Quick Start

```
# run this from your Terminal
npm install @safelytyped/ip-port
```

```typescript
// add this import to your Typescript code
import { IpPort } from "@safelytyped/ip-port"
```

__VS Code users:__ once you've added a single import anywhere in your project, you'll then be able to auto-import anything else that this library exports.

## Documentation

Looking for more detailed documentation? You'll find it under the [docs](./docs) folder.

* [Our public library API](./docs/api/v1.md)
* [Our CHANGELOG](CHANGELOG.md)
* [Our software license](LICENSE.md)
* [All contributors to date](AUTHORS.md)
npm package: @safelytyped/math-rounding
Description: Math rounding utilities
Latest version: 1.0.1

# Math Rounding Utilities for TypeScript

## Introduction

This TypeScript library adds missing math rounding utilities, in a type-safe manner.

## Quick Start

```
# run this from your Terminal
npm install @safelytyped/math-rounding
```

```typescript
// add this import to your Typescript code
import { roundDown } from "@safelytyped/math-rounding";
```

__VS Code users:__ once you've added a single import anywhere in your project, you'll then be able to auto-import anything else that this library exports.

## Exported Functions

### roundDown()

Use `roundDown()` to round a number down to the precision you require.

```typescript
import { roundDown } from "@safelytyped/math-rounding";

// res == 1.99
const res = roundDown(2, 1.9999);
```

### roundUp()

Use `roundUp()` to round a number up to the precision you require.

```typescript
import { roundUp } from "@safelytyped/math-rounding";

// res == 2
const res = roundUp(2, 1.99999);
```

### roundTo()

Use `roundTo()` if you want to inject your own rounding function.

```typescript
import { roundTo } from "@safelytyped/math-rounding";

// roundedDownRes == 1.99
const roundedDownRes = roundDown(
    Math.trunc,
    2,
    1.99999
);

// roundedUpRes == 2
const roundedDownRes = roundDown(
    Math.ceil,
    2,
    1.99999
);
```

## Why Another Math Rounding Package?

I found myself needing rounding functions in [CSS Color](https://github.com/SafelyTyped/ts-css-color) that Javascript's stock `Math` module doesn't provide. I've published them as a separate package so that I can reuse them in other packages in the future.

But this isn't the world's first package to add missing `Math` rounding functions to Javascript / Typescript ... so why have I built it?

The main reason is that it follows the SafelyTyped philosophy of function parameter order:

- required modifier params come first,
- then the main input value

I find that this makes partial functions a little more readable, such as:

```typescript
import { roundDown } from "@safelytyped/ts-math-rounding";

const roundDown2 = (x: number) => roundDown(2, x);
```

## Documentation

Here's a link to all the documentation about this project.

### Admin Paperwork

* [Our CHANGELOG](CHANGELOG.md)
* [Our software license](LICENSE.md)

### For Contributors

* [How to contribute](CONTRIBUTING.md)
* [Our Code of Conduct](CODE-OF-CONDUCT.md)
* [Our NPM scripts](./docs/v1/contributors/NPM-Scripts.md)

### Credits

* [Current Maintainers](MAINTAINERS.md)
* [All contributors to date](AUTHORS.md)

Follow us on [Twitter](https://twitter.com/SafelyTyped)!
npm package: @safelytyped/mediatype
Description: TypeScript support for RFC-2045 / RFC-6838 MediaTypes
Latest version: 0.2.1

# Welcome To @safelytyped/mediatype!

## Introduction

ADD YOUR INTRODUCTION HERE!!

## Quick Start

```
# run this from your Terminal
npm install @safelytyped/mediatype
```

```typescript
// add this import to your Typescript code
import { Value } from "@safelytyped/mediatype"
```

__VS Code users:__ once you've added a single import anywhere in your project, you'll then be able to auto-import anything else that this library exports.

## Documentation

Looking for more detailed documentation? You'll find it under the [docs](./docs) folder.

* [Our CHANGELOG](CHANGELOG.md)
* [Our software license](LICENSE.md)
* [All contributors to date](AUTHORS.md)
npm package: @safelytyped/node-pathapi
Description: The cross-platform bits of NodeJS's path module, as a protocol, for TypeScript.
Latest version: 1.1.1

# Welcome To @safelytyped/node-pathapi!

## Introduction

`@safelytyped/node-pathapi` is a [protocol][Protocol] library.

It provides a Typescript interface for [the NodeJS path module](https://nodejs.org/api/path.html) methods that work on both POSIX and Windows (ie, the interface that describes both `path.posix` and `path.win32`).

Use it to help you test libraries that take `path` as a dependency. See [the Filepath safe type](https://github.com/SafelyTyped/ts-filepath/) for a working example.

## Quick Start

```
# run this from your Terminal
npm install @safelytyped/node-pathapi
```

```typescript
// add this import to your Typescript code
import { PathApi } from "@safelytyped/node-pathapi"
```

__VS Code users:__ once you've added a single import anywhere in your project, you'll then be able to auto-import anything else that this library exports.

## Documentation

Looking for more detailed documentation? You'll find it under the [docs](./docs) folder.

Plus:

* [The PathApi](./src/v1/PathApi.ts) itself.
* [Our CHANGELOG](CHANGELOG.md)
* [Our software license](LICENSE.md)
* [All contributors to date](AUTHORS.md)

[Protocol]: https://github.com/SafelyTyped/ts-coding-standards/blob/master/glossary/protocol.md
npm package: @safelytyped/url
Description: A safe type for working with remote locations, for Typescript.
Latest version: 0.2.0

# Welcome To @safelytyped/url!

## Introduction

This is the README for `@safelytyped/url`. Rather than put all the docs in one, impossible-to-navigate file, this README is here to point you at where you can find all the documentation we've written.

## Quick Start

```
# run this from your Terminal
npm install @safelytyped/url
```

```typescript
// add this import to your Typescript code
import { URL } from "@safelytyped/url"
```

__VS Code users:__ once you've added a single import anywhere in your project, you'll then be able to auto-import anything else that this library exports.

## Documentation

Looking for more detailed documentation? You'll find it under the [docs](./docs) folder.

* [Our public API](./docs/api/)
* [Our reference documentation](./reference-docs/) (auto-generated; best viewed in a local clone of this Git repo!)
* [Our CHANGELOG](CHANGELOG.md)
* [Our software license](LICENSE.md)
* [All contributors to date](AUTHORS.md)