open-index/open-npm huggingface dataset:
npm package: @matthewglover/hapi-oauth
Description: Oauth login plugin for Hapi.js
Author: Matt Glover
Latest version: 0.1.1

[![Build Status](https://travis-ci.org/matthewglover/hapi-oauth.svg?branch=master)](https://travis-ci.org/matthewglover/hapi-oauth) [![Coverage Status](https://coveralls.io/repos/github/matthewglover/hapi-oauth/badge.svg?branch=master)](https://coveralls.io/github/matthewglover/hapi-oauth?branch=master)

# hapi-oauth

## What
A Hapi.js plugin providing Oauth login. Currently just for Facebook.

## Why
To implement a simple minimal oauth setup, and to learn more about oauth and plugins.

## How

To install, run `npm install --save @matthewglover/hapi-oauth`.

A simple implementation:

```javascript
const { createServer, setConnection, registerPlugins, addRoutes, startServer } =
  require('@matthewglover/hapi-wrapper');
const hapiOauth = require('@matthewglover/hapi-oauth');

const options = {
  configs: [
    {
      provider: 'facebook',                       // name of provider (currently only facebook)
      loginPath: '/fb-login',                     // path to start login process
      authPath: '/fb-auth',                       // path to complete login process
      redirectPath: '/process-login',             // path to handle any post-login
      baseUrl: 'your.domain.com',                 // base path of your domain (without)
      clientId: 'your-facebook-client-id',        // facebook client id
      clientSecret: 'your-facebook-client-secret',// facebook client secret
      options: {                                  // any additional params to be sent to provider
        scope: 'user_likes',
      },
    },
  ],
};


// Create plugin with options
const plugin = { register: hapiOauth, options };

// Example route to process data from login
// This is where you may wan to create a web token or cookie
const processLoginRoute = {
  method: 'GET',
  path: '/process-login',
  handler: (req, reply) => reply(req.query),
};


// Create a server, register plugin and add process-login route
const server =
  createServer()
  .then(setConnection({ port: 3000 }))
  .then(registerPlugins([plugin]))
  .then(addRoutes([processLoginRoute]))
  .then(startServer)
  .then(s => console.log(`Server running at: ${s.info.uri}`))
  .catch(err => console.error(err));

module.exports = server;
```
npm package: @matthewglover/hapi-wrapper
Description: Promise-based wrapper around Hapi
Author: Matt Glover
Latest version: 0.2.5

[![Build Status](https://travis-ci.org/matthewglover/hapi-wrapper.svg?branch=master)](https://travis-ci.org/matthewglover/hapi-wrapper) [![Coverage Status](https://coveralls.io/repos/github/matthewglover/hapi-wrapper/badge.svg?branch=master)](https://coveralls.io/github/matthewglover/hapi-wrapper?branch=master) [![Dependencies](https://david-dm.org/matthewglover/hapi-wrapper.svg)](https://david-dm.org/matthewglover/hapi-wrapper)

# Hapi Wrapper

## What
A Promise-based wrapper around Hapi.

## Why

Hapi has a number of hooks for configuring a server, some of which can be asynchronous. Hapi Wrapper uses Promises and simple functions which allow the different configuration steps to be composed together.

Hapi-Wrapper also includes Inert by default when you add routes configured to serve static resources from the `./public` folder.

## How

To include in your project run:

`npm install --save @matthewglover/hapi-wrapper`.

To create a server:

```javascript
const {
  createServer,
  setConnection,
  registerPlugins,
  addRoutes,
  startServer } = require('@matthewglover/hapi-wrapper');

const port = process.env.PORT || 4000;

createServer()
  .then(setConnection({ port }))
  .then(registerPlugins())
  .then(addRoutes())
  .then(startServer)
  .then(server => console.log(`Server running at: ${server.info.uri}`))
  .catch(err => console.log(err));
```
npm package: @matthewkennedy/json-api-deserializer
Description: Immutable json:api deserializer
Latest version: 1.0.0

[![CI](https://github.com/MatthewKennedy/json-api-deserialize/actions/workflows/ci.yml/badge.svg)](https://github.com/MatthewKennedy/json-api-deserialize/actions/workflows/ci.yml)
[![Lint Code Spelling](https://github.com/MatthewKennedy/json-api-deserialize/actions/workflows/spelling_lint.yml/badge.svg)](https://github.com/MatthewKennedy/json-api-deserialize/actions/workflows/spelling_lint.yml)
[![Standard JS](https://github.com/MatthewKennedy/json-api-deserialize/actions/workflows/standardjs.yml/badge.svg)](https://github.com/MatthewKennedy/json-api-deserialize/actions/workflows/standardjs.yml)

# {JSON:API} Deserializer

Immutable {json:api} deserializer

- [{json:api} spec](https://jsonapi.org/) compliant
- maps included objects to resources
- does not mutate original response object

## Install

```
yarn add deserialize-json-api
```

## Usage

```js
import { deserialize } from "deserialize-json-api";

const body = {
  data: {
    id: 1,
    type: "movie",
    attributes: { name: "test movie", year: 2014 },
    relationships: {
      actors: { data: [{ id: 1, type: "actor" }] },
      awards: {
        data: [
          {
            id: 4,
            type: "award",
            links: { self: "/awards/1" },
            meta: { verified: false },
          },
        ],
      },
    },
    links: { self: "/movies/1" },
    meta: { saved: false },
  },
  included: [
    {
      type: "actor",
      id: 1,
      attributes: { name: "John", age: 80 },
    },
    {
      type: "award",
      id: 4,
      attributes: { type: "Oscar", category: "Best director" },
    },
  ],
  meta: { copyright: "Copyright 2015 Example Corp." },
  errors: [{ title: "Error!" }],
};

const deserializedData = deserialize(body);

JSON.stringify(deserializedData) ===
  JSON.stringify({
    data: {
      id: 1,
      type: "movie",
      links: { self: "/movies/1" },
      meta: { saved: false },
      name: "test movie",
      year: 2014,
      actors: [
        {
          id: 1,
          type: "actor",
          name: "John",
          age: 80,
        },
      ],
      awards: [
        {
          id: 4,
          type: "Oscar",
          links: { self: "/awards/1" },
          meta: { verified: false },
          category: "Best director",
        },
      ],
    },
    meta: { copyright: "Copyright 2015 Example Corp." },
    errors: [{ title: "Error!" }],
  });
```

## Options

#### camelCase

If you would like to have your object key `camelCased` you can pass an option:

```javascript
const result = deserialize(body, { transformKeys: "camelCase" });
```

Currently the package will look for `-` and `_` characters and transform it into camelCase.

```
first-name -> firstName
first_name -> firstName
```

## Contributing

1. Fork it
2. Create your feature branch (`git checkout -b feature/fooBar`)
3. Commit your changes (`git commit -am 'Add some fooBar'`)
4. Push to the branch (`git push origin feature/fooBar`)
5. Create a new Pull Request
npm package: @matthewkennedy/spree-frontend
Description: A Modern Rails Storefront For Spree
Author: Matthew Kennedy
Latest version: 0.0.4

# Spree (Legacy) Frontend

This is the old Spree Storefront extracted from Spree < 4.3 which was upgraded to Turbo/Hotwire.

## Developed by

[![Vendo](https://assets-global.website-files.com/6230c485f2c32ea1b0daa438/623372f40a8c54ca9aea34e8_vendo%202.svg)](https://getvendo.com?utm_source=spree_frontend_github)

> All-in-one platform for all your Marketplace and B2B eCommerce needs. [Start your 30-day free trial](https://e98esoirr8c.typeform.com/contactvendo?typeform-source=spree_sdk_github)

## Installation

Add

```ruby
gem 'spree_frontend'
```

to your `Gemfile`.

Run:

```bash
bundle install
bin/rails g jsbundling:esbuild:install
bin/rails g turbo:install
bin/rails g spree:frontend:install
```

## Maintanence policy

This gem is in maintainence mode.

We only accept bug fixes, Spree/Rails compatibility improvements & security patches.

For new project we recommend using [Storefront API](https://api.spreecommerce.org/) to create your own unique storefront or use one of the pre-built starters: 

* [Next.js](https://dev-docs.spreecommerce.org/storefronts/next.js-commerce)
* [Vue Storefront](https://dev-docs.spreecommerce.org/storefronts/vue-storefront)

## Customization

[Developer documentation](https://dev-docs.spreecommerce.org/customization/storefront)
npm package: @matthewkennedy/stimulus-form-state
Description: A Stimulus controller for tracking changes on form elements.
Author: Matthew Kennedy
Latest version: 0.1.3

# Stimulus Form State
[![Test](https://github.com/MatthewKennedy/stimulus-form-state/actions/workflows/test.yml/badge.svg)](https://github.com/MatthewKennedy/stimulus-form-state/actions/workflows/test.yml)
[![Lint](https://github.com/MatthewKennedy/stimulus-form-state/actions/workflows/lint.yml/badge.svg)](https://github.com/MatthewKennedy/stimulus-form-state/actions/workflows/lint.yml)

## Getting started

A Stimulus controller for tracking changes to form elements such as: `<input>`, `<select>`, `<textarea>`
allowing you to manipulate the form submit `<button>` or other DOM elements if a form has changed from its original state.

## 📚 Documentation

### Install
```bash
yarn add stimulus-form-state
```

### Extending Controller
```javascript
// javascript/controllers/form_state_controller.js

import StimulusFormState from '@matthewkennedy/stimulus-form-state'

export default class extends StimulusFormState {

  // Override the change methods to manipulate the DOM as you wish.
  enableChangeControles () {
    // When a form element has been changed.
    document.getElementById('inputStateSubmitButton').style.display = 'inline'
    super.enableChangeControles()
  }

  disableChangeControles () {
    // If a previously changed form element is then set back to its original state.
    document.getElementById('inputStateSubmitButton').style.display = 'none'
    super.disableChangeControles()
  }
}
```

### In The DOM

Add `data-controller="form-state"` to the `<form>` wrapping the elements you want to track the state of, including the submit `<button>`.

Add `data-form-state-target="watch"` to the `<select>`, `<textarea>` or `<input>` elements that you want to track state of. The correct stimulus data-action will be added to the watched elements.

Add `data-form-state-target="saveButton"` to the from submit button, by default the button will be disabled unless a watched element is changed.

An example:
```html
<form data-controller="form-state" action="/customer" method="post">
  <input data-form-state-target="watch" type="text" value="Joe" name="first_name">
  <input data-form-state-target="watch" type="text" value="Blogs" name="last_name">
  <textarea data-form-state-target="watch" name="description">Some Value.</textarea>

  <button type="submit" data-form-state-target="saveButton">Save</button>
</form>
```

## 👷‍♂️ Contributing

Do not hesitate to contribute to the project by adapting or adding features ! Bug reports or pull requests are welcome.

## 📝 License

This project is released under the [MIT](http://opensource.org/licenses/MIT) license.
npm package: @matthewkilpatrick/strapi-plugin-editor-js
Description: A plugin to add an editor.js custom field to Strapi 5.
Author: Matthew Kilpatrick
Latest version: 0.0.0

# strapi-plugin-editor-js
A plugin to add an editor.js custom field to Strapi 5.

## Addons
The following Editor.js blocks are enabled by default:
- [Paragraph](https://github.com/editor-js/paragraph)
- [Header](https://github.com/editor-js/header)
- [Simple image](https://github.com/editor-js/simple-image) (integrated into the Strapi media library)
- [Embed](https://github.com/editor-js/embed)
- [List](https://github.com/editor-js/list)
- [Raw](https://github.com/editor-js/raw)
- [Quote](https://github.com/editor-js/quote)
- [Table](https://github.com/editor-js/table)

## Credits
This plugin is mostly duct-taped together based on the existing libraries, that don't yet support Strapi 5:
- https://github.com/melishev/strapi-plugin-react-editorjs
- https://github.com/GregorSondermeier/strapi-plugin-editorjs