open-index/open-npm huggingface dataset:
npm package: @marvinc.silva/sat
Description: use samples as templates
Author: MVCDS
Latest version: 1.0.1

# Samples As Templates

In a node project is common to have a folder structure where files follow some naming convention, to avoid copying and pasting on the folder's name and files you could type `sat` to use samples as templates

    $ yarn global add @marvinc.silva/sat

Test it by checking the version

    $ sat --version

You can also install it on the current project, for developers only.

    $ yarn add @marvinc.silva/sat --dev

In this case you'll need to refer to the bin folder

    $ node_modules/.bin/sat --version

## WIP

This project is a work in progess, therefore, it only worries about happy scenarios, so there aren't any exception handling and somethings will change for sure.

We welcome suggestions as issues on github.

## How to start using it

On your project's `package.json` file create an object `sat`, its keys will be considered as 'the name of your samples', and the value the sample itself.

      "sat": {
        "sampleA": "path\to\file.js",
        "sampleB": path\to\directory
      }

## Commands

To duplicate a sample use:

    sat use [sample] [name]

You can list all commands from the command line with:

    sat list

### Planned

    sat create [sample]
    sat delete [sample]
npm package: @marvinh/cancel-token
Description: Tiny cancel tokens similar to AbortController
Author: Marvin Hagemeister
Latest version: 1.0.1

# Simple async promise cancellation

Minimal implementation for cancel tokens, similar to `AbortController`, but
without the event handling. Uses the `throw` keyword under the hood but throws
a `string` to prevent expensive stack trace creation.

## Installation

```bash
npm install @marvinh/cancel-token
# or
yarn add @marvinh/cancel-token
```

## Usage

```js
import { CancelController } from "@marvinh/cancel-token";

const controller = new CancelController();
const signal = controller.signal;

doSomethingAsync()
  .then(() => {
    if (signal.aborted) throw "Aborted";
    // do something else
  })
  .catch(err => {
    if (err === "Aborted") {
      console.log("was aborted");
    }
  });
```

The above can be simplified with a helper function:

```js
import { CancelController, wrap } from "@marvinh/cancel-token";

const controller = new CancelController();
const signal = controller.signal;

wrap(doSomethingAsync(), signal).catch(err => {
  if (err === "Aborted") {
    console.log("was aborted");
  }
});
```

## License

`MIT`, see the [license file](./LICENSE.md).
npm package: @marvinh/fast-graphql-server
Description: This project is a fork of the excellent [apollo-server](https://github.com/apollographql/apollo-server). The main difference is a much smaller code-base and it currently only has an adapter for [micro-opinions](https://github.com/marvinhagemeister/micro-o
Author: Marvin Hagemeister
Latest version: 0.6.1

# Fast GraphQL Server

This project is a fork of the excellent [apollo-server](https://github.com/apollographql/apollo-server).
The main difference is a much smaller code-base and it currently only has an
adapter for [micro-opinions](https://github.com/marvinhagemeister/micro-opinions)

For the full doc please read the [apollo-server docs](https://github.com/apollographql/apollo-server)

## Installation

```bash
# npm
npm install --save @marvinh/fast-graphql-server

# yarn
yarn add @marvinh/fast-graphql-server
```

## Usage

```ts
import { mhGraphql, mhGraphiql } from "@marvinh/fast-graphql-server";
import { router, match } from "@marvinh/micro-opinions";
import micro from "micro";

// Your graphql schema
const file = fs.readFileSync("path/to/schema.graphql", "utf8");
const schema = buildSchema(file);

export function micro(async (req, res) => {
  const result = await router([
    match("GET", "/graphql", mhGraphql({ schema })),
    match("POST", "/graphql", mhGraphql({ schema })),

    // GraphiQL
    match("GET", "/graphiql", mhGraphiql({ endpointURL: "/graphql", })),
    match("POST", "/graphiql", mhGraphiql({ endpointURL: "/graphql", })),
  ])
});
```

# License

`MIT`, see [License file](./LICENSE.md)
npm package: @marvinh/instant-ssr
Description: Ultra fast server side templating engine
Author: Marvin Hagemeister
Latest version: 0.0.2

# Instant-SSR Server Runtime

This package includes the server runtime for [instant-ssr](https://github.com/marvinhagemeister/instant-ssr). See the parent [README](https://github.com/marvinhagemeister/instant-ssr) for
more information.

## License

`MIT`, see the [license file](./LICENSE.md).