open-index/open-npm huggingface dataset:
npm package: @gasbuddy/client-sqs
Description: A configuration driven SQS client
Author: GasBuddy Developers
Latest version: 1.0.1

client-sqs
===============

![main CI](https://github.com/gas-buddy/client-sqs/actions/workflows/nodejs.yml/badge.svg)

[![npm version](https://badge.fury.io/js/@gasbuddy%2Fclient-sqs.svg)](https://badge.fury.io/js/@gasbuddy%2Fclient-sqs)

A configuration driven SQS client
npm package: @gasbuddy/coconfig
Description: Default Node.js configuration files for GasBuddy projects
Author: GasBuddy Developers
Latest version: 2.0.0

# @gasbuddy/coconfig

![main CI](https://github.com/gas-buddy/gasbuddy-coconfig/actions/workflows/npm_publish.yml/badge.svg)

Default Node.js configuration files for GasBuddy projects. Uses [coconfig](/gas-buddy/coconfig)
to create a pile of configuration files.
npm package: @gasbuddy/configured-dynamodb-client
Description: A configuration driven DynamoDB client
Author: GasBuddy
Latest version: 1.3.0

configured-dynamodb-client
==========================

![Node CI](https://github.com/gas-buddy/configured-dynamodb-client/workflows/Node%20CI/badge.svg)

A small wrapper around the AWS DynamoDB sdk to allow configuration from confit.
npm package: @gasbuddy/configured-pino
Description: A configuration driven Pino logging infrastructure
Author: GasBuddy
Latest version: 2.3.1

configured-pino
==================

[![Greenkeeper badge](https://badges.greenkeeper.io/gas-buddy/configured-pino.svg)](https://greenkeeper.io/)

[![Coverage Status](https://coveralls.io/repos/github/gas-buddy/configured-pino/badge.svg?branch=master)](https://coveralls.io/github/gas-buddy/configured-pino?branch=master)

A trivial wrapper around [Pino](https://getpino.io) logging to be usable from existing @gasbuddy/service
infrastructure which was winston based.

Sample Configuration
====================
```
  "logger": {
    "module": "@gasbuddy/configured-pino",
    "level": "warn"
  }
```
npm package: @gasbuddy/configured-prometheus-client
Description: A configuration driven prometheus client
Author: GasBuddy
Latest version: 2.0.0

configured-prometheus-client
==========================

[![Greenkeeper badge](https://badges.greenkeeper.io/gas-buddy/configured-prometheus-client.svg)](https://greenkeeper.io/)

[![wercker status](https://app.wercker.com/status/92c79256cd694bc9066f61d4d6503b82/s/master "wercker status")](https://app.wercker.com/project/byKey/92c79256cd694bc9066f61d4d6503b82)

A small wrapper around the Prometheus client to allow configuration from JSON configuration or [hydration](https://github.com/gas-buddy/hydration).

You can create metrics "upfront":

```
import PrometheusClient from '@gasbuddy/configured-prometheus-client';

const client = new PrometheusClient({}, {
    histograms: {
      TestHisto: {
        help: 'Test Histogram',
        labels: ['foo', 'baz'],
        buckets: [0.1, 0.2, 1],
      },
    },
    counters: {
      TestCount: {
        help: 'Test Counter',
      },
    },
    gauges: {
      TestGauge: {
        help: 'Test Gauge',
      },
    },
    summaries: {
      TestSum: {
        help: 'Test Summary',
      },
    },
  });

// Increment the counter by 5
client.counters.TestCount.inc(5);
```

Also, since most things you want to time are some sort of asynchronous
operation, the client provides a "Promise timer" method:

```
async function aPromise(value) {
  await Promise.delay(1);
  return value;
}

const rz = await client.promiseTimer('TestHisto')
  .label({ foo: 'bar' })
  .labelSuccess(result => ({ baz: result }))
  .execute(aPromise('beep'));
// rz is now the result of the promise
```

The `foo:bar` label will be applied on the call to startTimer, and the
`baz:beep` label will be applied when the timer ends assuming the promise
resolves rather than rejects (use labelError for that case). Each of the
label functions accepts either a function (so you can examine the result of
the promise) or a literal object that just gets added to the labels.

(Note that literal labels applied with .label() will always be applied
when the timer STARTS, all others will be applied in order after it resolves or rejects).
npm package: @gasbuddy/configured-rabbitmq-client
Description: A configuration driven RabbitMQ client
Author: GasBuddy
Latest version: 9.0.0

configured-rabbitmq-client
==========================
A small wrapper around the foo-foo-mq to allow configuration from confit.

## Persistent messages
exchanges and queues are `durable` by default. You can make messages persistent in an exchangeGroup (primary, retry and rejected) by doing the following:
```
{
  "exchangeGroups": {
    "exchange.test.request.v1": {
      "persistent": true,
      "keys": "exchange.test"
    }
  }
}
```

 Follow [this link](https://github.com/gas-buddy/wiki/wiki/Persistent-rabbitMQ-messages) to see more options

## TTL
Only retry queue use TTL by default. You can set it by doing the following.

NOTE: **You cannot change TTL on an existing queue**.
```
{
  "exchangeGroups": {
    "exchange.test.request.v1": {
      ...
      "perMessageTtl": true, // It should be used on new exchange groups even if you don't change the default value
      "retryDelay": 60000, // default 10000ms
    }
  }
}
```
npm package: @gasbuddy/configured-rate-limiter
Description: A configuration driven rate limiter
Author: GasBuddy
Latest version: 1.1.1

configured-rate-limiter
=======================

This is a wrapper around [node-rate-limiter-flexible](https://github.com/animir/node-rate-limiter-flexible) to work in the
[@gasbuddy/service](https://github.com/gas-buddy/service) opinionated service
framework which uses Redis for other things. While the primary use is inside our
[Ambassador](https://www.getambassador.io/) based external-auth service, it is
useful to use the module in clients directly so that you can take advantage
of in-process caching for blocked users and to avoid unnecessary network traffic when a simple front-end rate limiter isn't enough.
npm package: @gasbuddy/configured-sns-client
Description: A configuration driven SNS client
Author: GasBuddy
Latest version: 1.1.2

configured-sns-client
==========================

![Node CI](https://github.com/gas-buddy/configured-sns-client/workflows/Node%20CI/badge.svg)

A small wrapper around the AWS SNS sdk to allow configuration from confit. This module focuses on publishing and consuming messages. Topic configuration for SNS is done OUTSIDE of this module (assumedly will be terraform or similar).

Usage
=====
To send a message, you must configure this module in your service

```
{
  "region": "us-east-1",
  "accountId": "1234",
  "module": "require:@gasbuddy/configured-sns-client"
}
```

Now, you can publish to a topic (Note: Your service's role must have permission to pubish to the SNS topic)

```
  configuredSnsClient.publish(req, 'topic', { some: 'message' });

  // OR (with message attributes)
  configuredSnsClient.publish(req, 'topic', { some: 'message' }, {
      MessageAttributes: {
        Event_Type: {
          DataType: 'String.Array',
          StringValue: JSON.stringify(['user.registered']),
        },
      },
  });
```

You can set `assumedRole` to assert that your service has that role at the time of hydration
```
  {
  "assumedRole": "abc-topic-publisher",
  "region": "us-east-1",
  ....
}
```
npm package: @gasbuddy/configured-sqs-client
Description: A configuration driven SQS client
Author: GasBuddy
Latest version: 1.9.0

configured-sqs-client
==========================

![Node CI](https://github.com/gas-buddy/configured-sqs-client/workflows/Node%20CI/badge.svg)

A small wrapper around the AWS SQS sdk and sqs-consumer to allow configuration from confit.
Unlike configured-rabbitmq-client, most queue configuration for SQS is done OUTSIDE of the
infrastructure here (assumedly will be terraform or similar). So this module focuses on publishing
and consuming messages, but with as similar an configuration specification as possible.

Usage
=====
See the test directory for sample usage. To send a message, you must configure a logical queue, something like:

```
{
  region: 'us-east-1',
  queues: {
    basic: 'basic_queue'
  }
}
```

Now, you can publish to this queue using:

```
  configuredSqsClient.publish(req, 'basic', { some: 'message' });
```

To receive this message, you would subscribe:

```
  sqs.subscribe(context, 'basic', async (req, message, envelope) => {
    // Do stuff, await stuff, throw errors, whatever
  });
```

If your handler throws an error, the redrive policy of the queue takes over. However, if your handler
marks that error with a property "deadLetter" that is either true or the name of another queue, the
failed attempt will be published on the target queue (either the deadLetter property of the queue that
was configured in your configured-sqs-client config, or the queue specified in the deadLetter error property).

Compression
=====
Max message size allowed through SQS is 256kb. You can compress/deflate your message if you think it could go over that limit.

```
  configuredSqsClient.publish(req, 'basic', { some: 'message' }, { compression: true });
```
The deflated message will automatically be inflated before delivering to a consumer

Testing this package
=====
```
docker run -p 9324:9324 gasbuddy/sqs-mock:latest
npm run test
```
npm package: @gasbuddy/configured-swagger-client
Description: A module that creates a set of swagger clients with support for inter-service tracing, custom certificates, and separated endpoint configuration
Author: GasBuddy
Latest version: 5.7.0

configured-swagger-client
=========================

[![wercker status](https://app.wercker.com/status/15fcfccb064836e35c8438135e37cd41/s/master "wercker status")](https://app.wercker.com/project/byKey/15fcfccb064836e35c8438135e37cd41)


GasBuddy has chosen [Swagger](http://swagger.io/) as our API format for all services. Luckily, a growing number of
partners are also using Swagger. Our services are written mostly in Node.js, and this module is an attempt to make the
process of wiring a Node.js project to Swagger services easier and more robust.

We have a variety of "independent components":

* -api - a Swagger API that is reachable by the outside world
* -serv - a Swagger API that is only reachable from other services
* -web - a non-Swagger service that exposts
* -job - a start-and-finish job that runs periodically or on demand

All of these components likely make use of other Swagger services. Each of these services is defined by a JSON swagger
specification and will use [small-swagger-codegen](https://github.com/gas-buddy/small-swagger-codegen) to generate a
client package. This is a departure from versions < 5.x of this library which generated a JSON spec and the
client was dynamically generated. THe value of pregeneration is full type information available at development time,
which includes autocompleting complex method names and request structures, which in a language like Javascript, can reduce
bugs significantly without losing the flexibility (since it's just a generator doing the typing work).

One of the other important things we do is create a "CorrelationId" - a single identifier which can be traced
all through the logs of all of the services that request touches. This module creates an easy way to pass that
CorrelationId along in dependent service calls.

See the tests for example usage, but here's a simple one:

```
import PetApi from 'a-node-module-from-small-swagger-codegen';

const petApi = new PetApi(req.gb.serviceFactory);

const pets = await services.Pets.findPetsByStatus({ status: 'pending' });
// pets.obj has your pets!
```

API Options
===========

The CorrelationId support is accomplished via a requestInterceptor option to the rest-api-support methods.
rest-api-support also supports adding headers (such as authorization headers) in this phase. Metric collection is also
enabled by the requestInterceptor/responseInterceptor pair.
npm package: @gasbuddy/configured-winston
Description: A configuration driven winston infrastructure
Author: GasBuddy
Latest version: 2.1.1

configured-winston
==================

[![Greenkeeper badge](https://badges.greenkeeper.io/gas-buddy/configured-winston.svg)](https://greenkeeper.io/)

[![wercker status](https://app.wercker.com/status/0c57068422ba008f646fc541d8357308/s/master "wercker status")](https://app.wercker.com/project/byKey/0c57068422ba008f646fc541d8357308)
[![Coverage Status](https://coveralls.io/repos/github/gas-buddy/configured-winston/badge.svg?branch=master)](https://coveralls.io/github/gas-buddy/configured-winston?branch=master)

A wrapper which hooks winston transports up via config. The config entry should have a
"transports" property which has a list of transports to configure. It is specified via
an object rather than array to allow enable/disable and multi-config file overlays (features
of [hydration](https://github.com/gas-buddy/hydration)
 and [confit](https://github.com/krakenjs/confit)) to work more cleanly across environments.

Sample Configuration
====================
```
  "logger": {
    "module": "@gasbuddy/configured-winston",
    "transports": {
      "file": {
        "name": "File",
        "filename": "/var/log/foobar.error.log",
        "config": {
          "level": "error"
        }
      }
    },
    "console": false
  }
```
npm package: @gasbuddy/express-promise-patch
Description: A monkey patch to express 4 to better handle promises in handlers (i.e. async methods)
Author: GasBuddy
Latest version: 1.0.4

express-promise-patch
=====================

A simple patch to express 4.x to better deal with async handler methods.
Without this patch, exceptions in these methods will usually end up as
uncaughtRejections disassociated from the request that caused them. This
patch normalizes them back to calls to next() with the error.
npm package: @gasbuddy/hydration
Description: Configuration oriented object construction
Author: GasBuddy
Latest version: 2.2.0

hydration
=========

[![Greenkeeper badge](https://badges.greenkeeper.io/gas-buddy/hydration.svg)](https://greenkeeper.io/)
[![wercker status](https://app.wercker.com/status/a5428878e57b34ee0e4cd2fa06938ed5/s/master "wercker status")](https://app.wercker.com/project/byKey/a5428878e57b34ee0e4cd2fa06938ed5)

This module allows runtime object creation from configuration files. It is a part of our
microservices framework. Whereas express-participating things have [meddleware](https://github.com/gas-buddy/meddleware)
which will instantiate and wire up handlers into express. hydration is an analog to that for things that are
NOT handlers, like database connections, third party service connections, or "global" resources like logstash.

The only thing non-obvious it does is deal with promises - such that all setup is complete before the root hydrate
promise is resolved - and mirror the configuration structure in the resultant object. In other words, a config like this:

```
{
  testing: {
    sub: {
      module: "require:./some_module"
    }
  },
  top: {
    module: "require:./other_module"
  },
  disabled: {
    enabled: false,
    module: 'totallyFake'
  }
}
```

Will result in a runtime object that looks like:

```
{
  testing: {
    sub: (the result of calling await start() on an instance of the class exported by some_module)
  },
  top: (the result of calling await start() on an instance of the class exported by other_module),
  disabled: null
}
```
npm package: @gasbuddy/interaction-composer
Description: A command line tool to build interaction models (for Alexa for now) based on an intermediate format that is easier to maintain in source control and across deployment environments.
Author: GasBuddy
Latest version: 1.6.3

interaction-composer
====================

A command line tool to build interaction models
(for Alexa for now) based on an intermediate
format that is easier to maintain in source
control and across deployment environments.

Usage
=====
```
npx @gasbuddy/interaction-composer <path to json file>
```

See the [test/model](./test/model) directory for a simple example that illustrates environment aware naming
and intent inclusion.

Shorthands
==========

One of the major goals of this module is to reduce the verbosity of intent expression. This includes centralizing relevant data in a single config (as opposed to spreading it around the intents, dialog and slot specifications), it includes support for YAML instead of JSON, and it includes expansion
capabilities.

Expansion
---------

Samples and slot samples support combinations. There are two main features, the bracket-pipe usage:

```
this is a test
this was a test
this will be a test
```

Can be expressed as
```
this [is|was|will be] a test
```

These combinations can include slots, and can also be empty. For example:

```
is [it|this {station}] open [|now|right now]
```

Will expand to:
```
is it open
is it open now
is it open right now
is this {station} open
is this {station} open now
is this {station} open right now
```

Additionally, you can use nested arrays (they're weird in YAML) to have common root patterns:

```
- [|more] [|{details}]
- -
  - about this [|{station}]
```

Which expands to:
```
more
more {details}
more about this
more about this {station}
more {details} about this
more {details} about this station
details
{details}
about this
about this {station}
{details} about this
{details} about this station
```
npm package: @gasbuddy/kms-crypto
Description: Crytography operations that use Amazon Key Management Service, with reasonable development time proxies
Author: GasBuddy Developers
Latest version: 5.1.2

kms-crypto
==========

![main CI](https://github.com/gas-buddy/kms-crypto/actions/workflows/nodejs.yml/badge.svg)

[![npm version](https://badge.fury.io/js/@gasbuddy%2Fkms-crypto.svg)](https://badge.fury.io/js/@gasbuddy%2Fkms-crypto)

The kms-crypto module creates a generic interface for Key Management Services which allows reasonably flexible usage between true cloud providers (currently only AWS) and local encryption (mostly for development).

The key resource name is used to differentiate between the service providers, and the service provider is embedded in encrypted values (e.g. ciphertext). PLEASE NOTE - the examples use `null:whatever` but DO NOT USE THAT IN PRODUCTION CODE. Your key should start with `kms:` and you should get that key ARN from the ops team.

```
import assert from 'assert';
import { createKmsCryptoProvider } from '@gasbuddy/kms-crypto';

(async () => {
  const kms = createKmsCryptoProvider({});
  const encBlob = kms.encrypt('null:whatever', 'somethingunique', 'testing123');
  const decBlob = kms.decrypt('somethingunique', encBlob);
  assert.equals(decBlob.toString(), 'testing123');
})();
```
npm package: @gasbuddy/mobx-flipper
Description: Mobx middleware for flipper
Author: Khorark
Latest version: 3.1.2

# Mobx Flipper

![screenshot of the plugin](http://i.imgur.com/EHdtxfE.png)

`flipper-plugin-mobx-debugger` allows you read React Native mobx logs inside [Flipper](https://fbflipper.com/) now:

- Action
- State comparison

## Get Started

1. Install [mobx-flipper](https://github.com/khorark/mobx-flipper) middleware and `react-native-flipper` in your React Native app:

```bash
yarn add mobx-flipper react-native-flipper
# for iOS
cd ios && pod install
```

2. Add the middleware:

- MobX

```javascript
import {spy} from 'mobx';
import {createMobxDebugger} from 'mobx-flipper';

const store = new Store(); // your store

if (__DEV__) {
  spy(createMobxDebugger(store));
}
```

- MobX-state-tree

```javascript
import {addMiddleware} from 'mobx-state-tree';
import {createMstDebugger} from 'mobx-flipper';

const store = new Store(); // your store

if (__DEV__) {
  addMiddleware(store, createMstDebugger(store));
}
```

3. Install [flipper-plugin-mobx-debugger](https://github.com/khorark/flipper-plugin-mobx-debugger) in Flipper desktop client:

```
Manage Plugins > Install Plugins > search "mobx-debugger" > Install
```

4. Start your app, then you should be able to see Mobx Debugger on your Flipper app

## Acknowledgement

This plugin is inspired by [flipper-plugin-redux-debugger](https://github.com/jk-gan/flipper-plugin-redux-debugger).
npm package: @gasbuddy/mst-async-storage
Description: Brings AsyncStorage support to mobx-state-tree for React Native projects.
Author: Steve Kellock
Latest version: 0.4.2

# mst-async-storage

A [mobx-state-tree](https://github.com/mobxjs/mobx-state-tree) extension granting your models React Native's `AsyncStorage` powers of persistance.

# Requirements

- `mobx-state-tree` 2.x or 3.x
- `react-native` >= 0.56
- `@react-native-async-storage/async-storage` >= 1.x.x

# Installing

```sh
yarn add mst-async-storage
```

# Usage

The following async actions are added:

```ts
import { types } from "mobx-state-tree"
import { withAsyncStorage } from "mst-async-storage"

export const NiceThingsModel = types
  .model("NiceThings")
  .props({
    unicorns: true,
    dragons: true,
    cake: true,
    spiders: false,
    nickleback: false,
  })
  .actions(self => ({
    setSpiders(value: boolean) {
      self.spiders = value
    },
  }))
  .extend(withAsyncStorage({ key: "nice.things" })) // <-- 🎉
```

Now you can load it:

```js
async demo () {
  // create your model as usual
  const happy = NiceThingsModel.create()

  // now load the data from async storage
  await happy.load()

  // and when you change something
  happy.setSpiders(true)

  // it will automatically save back to async storage!
}
```

# Options

`withAsyncStorage()` accepts an optional object as a parameter with these keys:

| key      | type             | what it does                                                                        |
| -------- | ---------------- | ----------------------------------------------------------------------------------- |
| key      | string           | The key to use when saving to AsyncStorage (default: the model type name)           |
| autoSave | boolean          | Should we automatically save when any values change on the model? (default: `true`) |
| only     | string, string[] | will only include the keys with these names                                         |
| except   | string, string[] | will omit keys with these names                                                     |

# Contributing?

Yes plz!

```
Fork it, Clone it, Branch it, Yarn it
Build it, Test it, Push it, PR it
```

To run the tests, I like to open two shells `yarn test:compile:watch` and `yarn test --watch`. If you run `ava` manually, make sure to add `-s` to run the tests serially because I fail mocking (because the mocks are shared state and bleed into each other).
npm package: @gasbuddy/react-navigation-codegen
Description: Type safe code generation for react-navigation based apps
Author: GasBuddy
Latest version: 5.5.0

react-navigation-codegen
========================

![Node CI](https://github.com/gas-buddy/react-navigation-codegen/workflows/Node%20CI/badge.svg)

A simple code generator to turn somewhat abstract specifications into TypeScript code with information about your full navigation stack in a React Navigation based app. This avoids lots of magic strings in your code, gives you a sense of the actual navigation structure, and avoids repeating yourself in code as much as usual.

Input can be YAML, JS, JSON, or Typescript. Consider a typical navigation setup:

```
type RootStackParamList = {
  Home: undefined;
  Profile: { userId: string };
  Feed: { sort: 'latest' | 'top' } | undefined;
};

const RootStack = createStackNavigator<RootStackParamList>();

<RootStack.Navigator initialRouteName="Home">
  <RootStack.Screen name="Home" component={Home} />
  <RootStack.Screen
    name="Profile"
    component={Profile}
    initialParams={{ userId: user.id }}
  />
  <RootStack.Screen name="Feed" component={Feed} />
</RootStack.Navigator>
```

With this module, you would specify as follows:

```
export default {
  screens: {
    Root: {
      parameterListType: 'RootStackParamList',
      screens: {
        Home: {},
        Profile: {
          parameterType: '{ userId: string }',
        },
        Feed: {
          parameterType: '{ sort: 'latest' | 'top' } | undefined',
        }
      }
    }
  }
}
```

And now your code becomes:

```
const RootStack = createStackNavigator<RootStackParamList>();

<RootStack.Navigator initialRouteName="Home">
  <RootStack.Screen name={Nav.Root.Home} component={Home} />
  <RootStack.Screen
    name={Nav.Root.Profile}
    component={Profile}
    initialParams={{ userId: user.id }}
  />
  <RootStack.Screen name={Nav.Root.Feed} component={Feed} />
</RootStack.Navigator>
```

Perhaps not a massive improvement in the simple example, but as you scale, it gets harder to manage all the types, related types and constants for every navigator, AND you lose a notion of the structure of the navigation tree.
npm package: @gasbuddy/redis-session
Description: A configuration driven session middleware for express.js
Author: GasBuddy Developers
Latest version: 3.0.3

redis-session
===============

![main CI](https://github.com/gas-buddy/redis-session/actions/workflows/nodejs.yml/badge.svg)

[![npm version](https://badge.fury.io/js/@gasbuddy%2Fredis-session.svg)](https://badge.fury.io/js/@gasbuddy%2Fredis-session)

A configuration driven session middleware for express.js
npm package: @gasbuddy/rest-api-support
Description: URL manipulation and other support infrastructure for making REST api calls
Author: GasBuddy Developers
Latest version: 1.15.0

rest-api-support
===============

![main CI](https://github.com/gas-buddy/rest-api-support/actions/workflows/nodejs.yml/badge.svg)

[![npm version](https://badge.fury.io/js/@gasbuddy%2Frest-api-support.svg)](https://badge.fury.io/js/@gasbuddy%2Frest-api-support)

URL manipulation and other support infrastructure for making REST api calls
npm package: @gasbuddy/service-tester
Description: Testing utilities for @gasbuddy/service
Author: GasBuddy Developers
Latest version: 12.3.0

service-tester
===============

![main CI](https://github.com/gas-buddy/service-tester/actions/workflows/nodejs.yml/badge.svg)

[![npm version](https://badge.fury.io/js/@gasbuddy%2Fservice-tester.svg)](https://badge.fury.io/js/@gasbuddy%2Fservice-tester)

This module makes it easier for you to write tests for your node.js GasBuddy microservice. Simply add
the module as a dev dependency:

```sh
yarn add -D @gasbuddy/service-tester
```

Then write a test in ```/__tests__/startup.test.js```:

```ts
import request from 'supertest';
import { getReusableApp, clearReusableApp } from '@gasbuddy/service-tester';
import myService from '../src/index';

describe('my service', () => {
  test('should start', async () => {
    const app = await getReusableApp(myService);
    expect(app).toBeTruthy();
    await request(app).get('/').expect(200);
  });
});
```

Service call mocking
--

Nock is so 2010. The future is mock! Since we have typed clients for services these days, mocking them is easier. We've played some nutty
tricks with Typescript (well, nutty for me), to enable this kind of syntax:

```
  mockServiceCall(app.locals.services.myCrazyServ, 'get_some_resource').mockResolvedValue({
    status: 200,
    responseType: 'response',
    body: { resource: true },
    headers: new Headers(),
  });
```

This will cause calls to `app.locals.services.myCrazyServ.get_some_resource()` to return `{resource: true}`. This is just shorthand
for `jest.spyOn(service, 'method')` with knowledge of the traditional return type of OpenAPI service calls.
npm package: @gasbuddy/service-types
Description: Common type declarations for GasBuddy services
Author: GasBuddy
Latest version: 1.0.0

@gasbuddy/service-types
=======================

![Node CI](https://github.com/gas-buddy/service-types/workflows/Node%20CI/badge.svg)

Common type declarations for GasBuddy services, separated to make it easier to write modules
intended to be used in those service without depending on all the service infrastructure.
npm package: @gasbuddy/swagger-ref-resolver
Description: A module to convert $refs in swagger to deal with tooling that can't handle composition (and gives you some extra superpowers)
Author: GasBuddy
Latest version: 5.2.0

swagger-ref-resolver
====================

Swagger and the swagger ecosystem are not especially well suited to
document composition. In our case, we want to group a set of related
operations into a single service/API, but they have a small but natural
set of groupings. The aggregate swagger document can be unwieldy as a single
file. The swagger-ref-resolver module allows you to create a composite
swagger doc made of multiple *valid* swagger subdocuments. For example:

```
{
    "swagger": "2.0",
    "paths": {
        "$ref": [
            "./someCoolStuff.json#paths",
            "./someBoringStuff.json#paths"
        ]
    },
    "definitions": {
        "$ref": [
            "./common.json#definitions",
            "./someCoolStuff.json#definitions",
            "./someBoringStuff.json#definitions"
        ]
    }
}
```

In the above example, someCoolStuff and someBoringStuff can be fully valid
swagger documents that can be edited in [Swagger Editor](http://editor.swagger.io).

swagger-ref-resolver can then take the root swagger doc and turn it into a
normal single-file swagger doc. It can do this at "runtime" or via a CLI 
(for example to be used in a prepublish script).
npm package: @gasbuddy/web-app
Description: A specialized @gasbuddy/service meant to run isomorphic React apps with Redis sessions
Author: GasBuddy Developers
Latest version: 1.5.2

@gasbuddy/web-app
=================

![main CI](https://github.com/gas-buddy/web-app/actions/workflows/npm_publish.yml/badge.svg)

[![npm version](https://badge.fury.io/js/@gasbuddy%2Fweb-app.svg)](https://badge.fury.io/js/@gasbuddy%2Fweb-app)

A specialized @gasbuddy/service meant to run isomorphic React apps with Redis sessions. Currently this just sets up session handling, but shortly will handle setting up a React rendering chain and webpack middleware.
npm package: @gasbuddy/web-coconfig
Description: Default Node.js configuration files for GasBuddy projects
Author: GasBuddy Developers
Latest version: 1.3.0

# @gasbuddy/web-coconfig

![main CI](https://github.com/gas-buddy/web-coconfig/actions/workflows/npm_publish.yml/badge.svg)

[![npm version](https://badge.fury.io/js/@gasbuddy%2Fweb-coconfig.svg)](https://badge.fury.io/js/@gasbuddy%2Fweb-coconfig)

Default Node.js configuration files for GasBuddy web projects. Uses [coconfig](/gas-buddy/coconfig) to create a pile of configuration files.
npm package: @gasco/core
Description: Base components for Gasco
Author: yoydev
Latest version: 0.0.25

# @gasco/core

[Gasco](https://gasco-web-component.herokuapp.com/) es un Framework que facilita la creación de aplicaciones web nativas y progresivas de alta calidad con tecnologías web.

El paquete `@gasco/core` contiene los componentes web que conforman los componentes básicos de la interfaz de usuario reutilizables de Gasco Framework. Estos componentes están diseñados para usarse en bibliotecas/Frameworks  (como [Stencil](https://stenciljs.com/), React, Angular o Vue), o solos a través de JavaScript tradicional en el navegador.

## Características

* Representación asíncrona
* No se requiere construir o compilar
* Componentes con carga diferida sin configuración
* Simplemente agregue los archivos estáticos a cualquier proyecto
* Componentes diminutos y altamente optimizados creados con [Stencil](https://stenciljs.com/)

## Cómo utilizarlos

### Vanilla HTML

La forma más fácil de comenzar a usar `@gasco/core` es agregar una etiqueta de secuencia de comandos a la CDN:

```html
<script type="module" src="https://cdn.jsdelivr.net/npm/@gasco/core/dist/gasco/gasco.esm.js"></script>
<script nomodule src="https://cdn.jsdelivr.net/npm/@gasco/core/dist/gasco/gasco.js"></script>
<link href="https://cdn.jsdelivr.net/npm/@gasco/core/css/gasco.bundle.css" rel="stylesheet">
```
Cualquier componente Gasco agregado a la página web se cargará automáticamente. Esto incluye escribir la etiqueta del componente directamente en HTML o usar JavaScript como `document.createElement('gasco-button')`.

Además, dentro de este paquete hay un archivo `dist/gasco.js` y el directorio adjunto `dist/gasco/`. Estos son los mismos archivos que usa la CDN y están disponibles en este paquete para que puedan ser parte del desarrollo local de una aplicación.

## Framework Bindings

El paquete `@gasco/core` se puede usar en HTML simple o JavaScript estándar sin ningún marco. Gasco también tiene paquetes que facilitan la integración de Gasco en el ecosistema y los patrones tradicionales de un Framework. (Sin embargo, en el marco de trabajo de nivel más bajo, los enlaces aún usan `@gasco/core` y Web Components).

### Uso de controladores superpuestos

Al usar un controlador de superposición, los desarrolladores deberán definir el componente de superposición antes de poder usarlo. A continuación se muestra un ejemplo del uso de `toastController`:


```typescript
import { defineCustomElement } from '@gasco/core/components/gasco-toast.js';
import { toastController } from '@gasco/core/components';

defineCustomElement();

const showToast = async () => {
  const modal = await toastController.create({ ... });
  
  ...
}
```
npm package: @gash21/i-just-ask-jokoui
Description: I Just Ask Joko UI - MCP server for joko-ui - Free Open Source Tailwind CSS Components
Author: Galih Arghubi
Latest version: 1.0.2

# I Just Ask - Joko UI (MCP Server)

A [Model Context Protocol (MCP)](https://modelcontextprotocol.io) server for [Joko UI](https://jokoui.web.id) - free open source Tailwind CSS components.

This server allows AI assistants (Claude Desktop, OpenCode, Cursor, etc.) to search, browse, and implement production-ready Joko UI components directly into your codebase.

## Features

- **Search**: Find components by name, description, or tags.
- **Fetch & Implement**: Get code from jokoui.web.id and write it to your project in one step.
- **Browse**: List all available components by category (Application/Marketing).
- **Zero Config**: "It just works" with most Tailwind projects.

## 📚 Documentation

- **[Installation Guide](INSTALL.md)** - Detailed setup for Claude, OpenCode, Cursor, and more.
- **[Tools & API](TOOLS.md)** - Full reference of available tools (`search_components`, `fetch_component`, etc.).
- **[Usage & Workflows](USAGE.md)** - Examples of how to use the server effectively.
- **[Development](CONTRIBUTING.md)** - Guide for contributors.
- **[Deployment](DEPLOYMENT.md)** - How to publish and deploy.

## 🚀 Installation

### Automatic Installation (Recommended)

The easiest way to install and configure the server for Claude Desktop, OpenCode, and Cursor.

```bash
Install and configure I Just Ask - Joko UI (MCP Server) by following the instructions here:
https://raw.githubusercontent.com/Gash21/i-just-ask-jokoui/refs/heads/main/INSTALL.md
```

### For AI Agents

If you are an AI assistant (Claude, etc.) reading this, you can install the server for the user with this one-liner (uses npm):

```bash
curl -fsSL https://raw.githubusercontent.com/Gash21/i-just-ask-jokoui/main/install.sh | bash -s -- --npm all
```
> **Note**: This will install the package from npm and configure all detected tools (Claude Desktop, OpenCode, Cursor, etc.).

### Manual Installation & npm

For manual steps or npm installation, see the **[Installation Guide](INSTALL.md)**.

## Available Components

**Application UI:**
- Auth Forms (Login, Register, Reset)
- Admin Dashboards & Sidebars
- Settings Pages
- data Tables & Charts

**Marketing UI:**
- Hero Sections
- Feature Grids
- Pricing Tables
- Footers

## Links

- [Joko UI Website](https://jokoui.web.id)
- [GitHub Repository](https://github.com/rayasabari/joko-ui)
- [Model Context Protocol](https://modelcontextprotocol.io)

## License

MIT
npm package: @gash48/react-native-flip-card
Description: The card component which has a motion of flip for React Native(iOS/Android)
Author: Gash
Latest version: 3.5.7

react-native-flip-card
===

> The card component which have motion of flip for React Native(iOS/Android)

[![NPM](https://nodei.co/npm/react-native-flip-card.png?downloads=true&downloadRank=true&stars=true)](https://nodei.co/npm/react-native-flip-card/)

[![npm](https://img.shields.io/npm/v/react-native-flip-card.svg)]()[![npm](https://img.shields.io/npm/l/react-native-flip-card.svg)]()

[![js-standard-style](https://cdn.rawgit.com/feross/standard/master/badge.svg)](https://github.com/feross/standard) [![forthebadge](http://forthebadge.com/images/badges/uses-js.svg)](http://forthebadge.com)

Demo
---
![](./doc/ver3_android_demo.gif)


Installation
==

in Cli
---
```
npm i react-native-flip-card
```


Usage
===

Simple
---
```
import FlipCard from 'react-native-flip-card'

<FlipCard>
  {/* Face Side */}
  <View style={styles.face}>
    <Text>The Face</Text>
  </View>
  {/* Back Side */}
  <View style={styles.back}>
    <Text>The Back</Text>
  </View>
</FlipCard>
```

Customized
---
```
<FlipCard 
  style={styles.card}
  friction={6}
  perspective={1000}
  flipHorizontal={true}
  flipVertical={false}
  flip={false}
  clickable={true}
  onFlipEnd={(isFlipEnd)=>{console.log('isFlipEnd', isFlipEnd)}}
>
  {/* Face Side */}
  <View style={styles.face}>
    <Text>The Face</Text>
  </View>
  {/* Back Side */}
  <View style={styles.back}>
    <Text>The Back</Text>
  </View>
</FlipCard>
```

Props
===

flip(bool) `Default: false`
---
If you change default display side, you can set `true` to this param. If you change side, you can pass `bool` variable dynamically.

clickable(bool) `Default: true`
---
If you want to disable click a card, you can set `false` to this param.

friction(number) `Default: 6`
---
The friction of card animation

perspective(number) `Default: 0`
---
The amount of perspective applied to the flip transformation

flipHorizontal(bool) `Default: false`
---
If you set true, a card flip to horizontal.

![](./doc/ver2_horizontal.gif)


flipVertical(bool) `Default: true`
---
If you set false, a card not flip to vertical. If you set true both `flipHorizontal` and `flipVertical` , a card flip to diagonal.


vertical | diagnoal
---- | ----
 ![](./doc/ver2_vertical.gif)| ![](./doc/ver2_diagonal.gif)

onFlipStart(function) `(isFlipStart) => {}`
---
When a card starts a flip animation, call `onFlipEnd` function with param.

onFlipEnd(function) `(isFlipEnd) => {}`
---
When a card finishes a flip animation, call `onFlipEnd` function with param.

alignHeight(boolean) `Default:false`
---
If you pass `true` to `alignHeight` param, the card keep height of bigger side.

alignWidth(boolean) `Default:false`
---
If you pass `true` to `alignWidth` param, the card keep width of bigger side.

useNativeDriver(boolean) `Default:false`
---
If you pass `true` to `useNativeDriver` param, the card animation will utilize the native driver.

Credits
===
Inspired by [react-flipcard](https://github.com/mzabriskie/react-flipcard)


License
===
MIT
npm package: @gasket/assets
Description: Gasket assets
Author: GoDaddy Operating Company, LLC
Latest version: 7.5.2

# @gasket/assets

Gasket related visual assets

## Installation

```
npm i @gasket/assets
```

## Usage

Original SVGs are available, however the primary use case will to be import the
ready-to-use components for your app. Currently these are available for React.

### React

Import a logo or other asset directly and use as you would any other React
component. You can use `className` or `style` props to adjust size, position,
etc.

```jsx
// demo-page.js

import React from 'react';
import GasketLogo from '@gasket/assets/react/gasket-logo';

const DemoPage = () => {
  <p>
    <GasketLogo style={{ width: '100px' }} />
  </p>
}
```

## Development

Add any new SVG files to the ./svg directory then run `npm run generate` to
output the importable components.

## License

[MIT](./LICENSE.md)
npm package: @gasket/cjs
Description: Utility for transpiling ESM to CJS with .cjs extensions
Author: GoDaddy Operating Company, LLC
Latest version: 7.1.2

# @gasket/cjs

Utility for transpiling ESM to CJS with .cjs extensions

## Installation

```bash
pnpm install @gasket/cjs
```

## Usage

### CLI

```bash
# Transpile from ./lib to ./cjs (default)
gasket-cjs

# Transpile from custom source directory
gasket-cjs ./src

# Transpile to custom output directory
gasket-cjs ./src ./dist/cjs
```

### Programmatic API

```javascript
import { transpile } from '@gasket/cjs';

// Basic usage
const result = await transpile('./src', './cjs');

// With options
const result = await transpile('./src', './cjs', {
  extensions: ['.js', '.mjs', '.ts'],
  createPackageJson: true,
  onProgress: ({ file, current, total }) => {
    console.log(`Processing ${file} (${current}/${total})`);
  }
});

console.log(`Transpiled ${result.successful.length} files`);
```

## Configuration

The utility uses SWC for transpilation with the following default configuration:

- **Module type**: CommonJS
- **Target**: ES2020
- **Extensions**: `.js`, `.mjs`
- **Output extension**: `.cjs`

## Features

- ✅ Transpiles ESM to CJS using SWC
- ✅ Changes file extensions from `.js`/`.mjs` to `.cjs`
- ✅ Fixes import paths to use `.cjs` extensions
- ✅ Creates `package.json` in output directory
- ✅ Preserves directory structure
- ✅ CLI and programmatic interfaces
- ✅ Progress reporting

## API Reference

### `transpile(sourceDir, outputDir, options)`

Main transpilation function.

#### Parameters

- `sourceDir` (string): Source directory path
- `outputDir` (string, optional): Output directory path (default: 'cjs')
- `options` (object, optional): Configuration options

#### Options

- `swcConfig` (object): Custom SWC configuration
- `extensions` (string[]): File extensions to process (default: ['.js', '.mjs'])
- `createPackageJson` (boolean): Create package.json in output dir (default: true)
- `onProgress` (function): Progress callback function

#### Returns

Promise resolving to TranspileSummary object:

```javascript
{
  successful: TranspileResult[],
  failed: TranspileResult[],
  total: number,
  outputDir: string
}
```

## License

[MIT licensed](./LICENSE.md).
npm package: @gasket/plugin-cypress
Description: Integrates Cypress based testing into your Gasket application
Author: GoDaddy Operating Company, LLC
Latest version: 7.5.4

# @gasket/plugin-cypress

Creates a Cypress-based testing environment for your Gasket application.

## Installation

This plugin is only used by presets for `create-gasket-app` and is not
installed manually for applications. It is automatically included when using
specific presets.

## Usage

When you create a new Gasket application that includes the
`@gasket/plugin-cypress`, it configures a Cypress-based testing environment. It
will automatically add the following `scripts` to your `package.json`:

- `npm run cypress`: Opens the Cypress Test Runner using the default
  configuration values from `cypress.config.js`. It runs all tests specified in
  the **test** folder.
- `npm run cypress:headless`: Runs all Cypress tests to completion in headless
  mode. The tests should be located in the **test** folder, or in the folder
  defined by `integrationFolder` in the `cypress.config.js` configuration.
- `npm run e2e`: Starts the Next.js production server (`next start`) and opens
  the Cypress Test Runner for end-to-end testing. The server runs at
  `http://localhost:3000` by default.
- `npm run e2e:headless`: Similar to `npm run e2e`, but runs the Cypress tests
  to completion in headless mode.

### Important Notes

- Before running `npm run cypress` or `npm run cypress:headless`, make sure the
  server is running in a separate terminal tab. You can start the server by
  running `npm run start` (or `npm run start:local`).
- Before starting the server for the first time, you must run
  `npm run build` to ensure that all necessary assets are built and available
  for testing.

## Additional Configuration

The plugin automatically detects if your project is a React-based application
and adjusts its setup accordingly:

- For React projects, it adds additional dependencies like
  `start-server-and-test` for easier server and test management.
- Test files and configuration files will be added under a generator directory.

## License

[MIT](./LICENSE.md)
npm package: @gasket/plugin-docs-graphs
Description: Generate mermaid graphs of an applications gasket lifecycles
Author: GoDaddy Operating Company, LLC
Latest version: 7.4.2

# @gasket/plugin-docs-graphs

The plugin hooks the **docsGenerate** lifecycle to provide a [`mermaid`] graph
of a given application's lifecycles.

## Installation

```
npm i @gasket/plugin-docs-graphs
```

Update your `gasket` file plugin configuration:

```diff
// gasket.js

+ import pluginDocsGraphs from '@gasket/plugin-docs-graphs';

 export default makeGasket({
  plugins: [
+   pluginDocsGraphs
  ]
});
```

[`mermaid`]: https://mermaid-js.github.io/mermaid/#/
npm package: @gasket/plugin-docusaurus
Description: Gasket plugin for docusaurus
Author: GoDaddy Operating Company, LLC
Latest version: 7.5.2

# @gasket/plugin-docusaurus

Use [Docusaurus] to serve a website view of the collated docs from [@gasket/plugin-docs].

## Installation

```
npm i @gasket/plugin-docs @gasket/plugin-docusaurus
```

Update your `gasket` file plugin configuration:

```diff
// gasket.js

+ import pluginDocusarus from '@gasket/plugin-docusaurus';
+ import pluginDocs from '@gasket/plugin-docs';

export default makeGasket({
  plugins: [
+   pluginDocs
+   pluginDocusarus
  ]
});
```

Now, when you run `npx gasket docs` in your app, a nice Docusaurus website will be
launched in your browser.

## Configuration

To be set under `docusaurus` in the `gasket.js`.

- `rootDir` - (string) Root Docusaurus directory. Default is `.docs`.
- `docsDir` - (string) Sub-directory for the generated markdown from the docs plugin. Default is `docs`.
- `port` - (number) Port to serve the docs from. Default is `3000`.
- `host` - (string) Hostname to serve the docs from. Default is `localhost`.

#### Example

```js
// gasket.js

 export default makeGasket({
  docusaurus: {
    rootDir: 'my-site-documents',
    docsDir: 'markdown',
    port: 8000,
    host: 'custom-host'
  }
});

// structure
gasket-app/ // app root
|_ my-site-documents // docusaurus root
  |_ .docusaurus // build folder
  |_ markdown // generated docs from @gasket/plugin-docs
```

### `docusaurus.config.js`

A required `docusaurus.config.js` will be generated in the root directory if one is not present. Docusaurus allows for additional [configuration/customization](https://docusaurus.io/docs/api/docusaurus-config) options. Define these directly in the `docusaurus.config.js`.

## License

[MIT](./LICENSE.md)

<!-- LINKS -->
[Docusaurus]: https://docusaurus.io/
[@gasket/plugin-docs]: /packages/gasket-plugin-docs/README.md