open-index/open-npm huggingface dataset:
npm package: @jasongorst/actiontext
Description: Edit and display rich text in Rails applications
Author: Basecamp, LLC
Latest version: 7.0.2-2

# Action Text

Action Text brings rich text content and editing to Rails. It includes the [Trix editor](https://trix-editor.org) that handles everything from formatting to links to quotes to lists to embedded images and galleries. The rich text content generated by the Trix editor is saved in its own RichText model that's associated with any existing Active Record model in the application. Any embedded images (or other attachments) are automatically stored using Active Storage and associated with the included RichText model.

You can read more about Action Text in the [Action Text Overview](https://edgeguides.rubyonrails.org/action_text_overview.html) guide.

## Development

The JavaScript for Action Text is distributed both as a npm module under @rails/actiontext and via the asset pipeline as actiontext.js (and we mirror Trix as trix.js). To ensure that the latter remains in sync, you must run `yarn build` and checkin the artifacts whenever the JavaScript source or the Trix dependency is bumped. CSS changes must be brought over manually to app/assets/stylesheets/trix.css

## License

Action Text is released under the [MIT License](https://opensource.org/licenses/MIT).
npm package: @jasonhaven/nextjs-basic-auth
Description: Simple Basic Auth implemention for Next.js applications.
Author: J.C. Hiatt
Latest version: 0.1.2

# NextJS Basic Auth

This package makes it simple to add Basic HTTP Auth to your Next.js application. Note that it **requires** you to opt out of static generation for any routes you want to protect, due to the fact that it needs to be called inside `getServerSideProps`.

## Installation

```
yarn add nextjs-basic-auth
```

## Setup

Initialize by importing and passing an object containing containing a `users` key, the value of which should be an array of users (use `user` and `password` as the keys for each respective user object):

```
import initializeBasicAuth from 'nextjs-basic-auth'
const users = [
  { user: 'user1', password: 'toocool' },
  { user: 'admin', password: 'password' },
]
const basicAuthCheck = initializeBasicAuth({
  users: users
})
```

This will return a function to you that you can call with two arguments: `req` and `res`.

## Usage

Provided you have initialized the package already, you can await the returned function inside `getServerSideProps` of any route(s).

```
// some-route.js
export async function getServerSideProps(ctx) {
  const {req, res} = ctx

  await basicAuthCheck(req, res)

  return {
    props: {}
  }
}
```

If the user input cannot be authenticated, the user will receive a 401 and a prompt to re-enter credentials.
npm package: @jasonheecs/heroku-vim
Description: Install Vim and use it in a Heroku dyno
Author: Jason Hee @jasonheecs
Latest version: 1.0.1

# heroku-vim
[![Build Status][travis-badge]][travis-link] [![Coverage Status][coveralls-badge]][coveralls-link]

A Heroku plugin that allows you to use vim in a dyno

## Installation
`heroku plugins:install @jasonheecs/heroku-vim`

## Usage
`heroku vim -a <app-name>`

This will install vim and start a bash session on the dyno

<br/>

You can set a command other than `bash` to be run as well:

`heroku vim -c 'rails console' -a <app-name>`

## License
MIT

[coveralls-badge]: https://coveralls.io/repos/github/jasonheecs/heroku-vim/badge.svg?branch=master
[coveralls-link]: https://coveralls.io/github/jasonheecs/heroku-vim?branch=master
[travis-badge]: https://travis-ci.com/jasonheecs/heroku-vim.svg?branch=master
[travis-link]: https://travis-ci.com/jasonheecs/heroku-vim
npm package: @jasonheecs/js-data-structures
Description: A list of common data structures implemented in Javascript
Author: jasonheecs
Latest version: 1.2.0

# Data Structures in Javascript
[![Build Status](https://travis-ci.org/jasonheecs/js-data-structures.svg?branch=master)](https://travis-ci.org/jasonheecs/js-data-structures) [![Coverage Status](https://coveralls.io/repos/github/jasonheecs/js-data-structures/badge.svg?branch=master)](https://coveralls.io/github/jasonheecs/js-data-structures?branch=master)

A package containing implementations of various data structures in Javascript. This project is mainly a learning exercise and personal refresher on the common CS data structures, in addition to playing around with test coverage reports with [coveralls](https://coveralls.io/)

## Installation
`npm install @jasonheecs/js-data-structures --save`

## Data Structures
- [Binary Search Tree](src/binary-search-tree.js)
- [Singly Linked List](src/singly-linked-list.js)
- [Doubly Linked List](src/doubly-linked-list.js)
- [Circular Linked List](src/circular-linked-list.js)
- [Queue](src/queue.js)
- [Stack](src/stack.js)
- [Trie](src/trie.js)
- [Min Heap](src/min-heap.js)
- [Graph](src/graph.js)

## Usage
```js
    var {BST} = require('@jasonheecs/js-data-structures');
    var {List} = require('@jasonheecs/js-data-structures');
    var {Trie} = require('@jasonheecs/js-data-structures');

    var bst = new BST();
    bst.add(10);
    bst.add(5);
    bst.add(15);

    console.log(bst.inOrder()); // [5, 10, 15]


    var linkedList = new List();
    linkedList.add(1);
    linkedList.add(2);
    linkedList.add(3);

    console.log(linkedList.search(2)); // Node { value: 2, next: Node { value: 3, next: null } }


    var trie = new Trie();
    trie.addWord('cat');
    trie.addWord('car');
    trie.addWord('dog');

    console.log(trie.find('ca')); 
    /** Node { value: 'a', children: Map {
         't' => Node { value: 't', children: Map {}, isCompleteWord: true },
         'r' => Node { value: 'r', children: Map {}, isCompleteWord: true } },
        isCompleteWord: false } **/
```

## Running unit tests
`npm test`

To run a specific test file, you can use an extra `--` to pass the filename through:  
`npm test -- test/binary-search-tree-test.js`

## License
MIT
npm package: @jasonheecs/js-sorting
Description: A list of common sorting algorithms implemented in Javascript
Author: jasonheecs
Latest version: 1.0.2

# Sorting Algorithms in Javascript
[![Build Status](https://travis-ci.org/jasonheecs/js-sorting.svg?branch=master)](https://travis-ci.org/jasonheecs/js-sorting) [![Coverage Status](https://coveralls.io/repos/github/jasonheecs/js-sorting/badge.svg)](https://coveralls.io/github/jasonheecs/js-sorting)

A package containing implementations of various sorting algorithms in Javascript. This project is mainly a learning exercise and personal refresher on the common CS sorting algos, in addition to playing around with test coverage reports with [coveralls](https://coveralls.io/)

## Installation
`npm install @jasonheecs/js-sorting --save`

## Usage
```js
    var {selectionSort} = require('@jasonheecs/js-sorting');
    var {bubbleSort} = require('@jasonheecs/js-sorting');
    var {insertionSort} = require('@jasonheecs/js-sorting');
    var {mergeSort} = require('@jasonheecs/js-sorting');
    var {quickSort} = require('@jasonheecs/js-sorting');

    var items = [5, 2, 1, 3, 6, 4];

    console.log(selectionSort(items));
    console.log(bubbleSort(items));
    console.log(insertionSort(items));
    console.log(mergeSort(items));
    console.log(quickSort(items));
```

## Running unit tests
`npm test`

To run a specific test file, you can use an extra `--` to pass the filename through:  
`npm test -- test/bubble-sort-test.js`

## License
MIT