open-index/open-npm huggingface dataset:
npm package: @roiarthurb/theme-github-codeblock
Description: A Docusaurus v2 plugin that supports referencing code examples from public GitHub repositories.
Author: Open Source Program Office Sauce Labs
Latest version: 0.2.4

Docusaurus Theme GitHub Codeblock ![Test Changes](https://github.com/saucelabs/docusaurus-theme-github-codeblock/workflows/Test%20Changes/badge.svg?branch=main)
=================================

A Docusaurus v2 plugin that supports referencing code examples from public GitHub repositories.

> Note: this theme plugin requires [Docusaurus v2](https://v2.docusaurus.io/)

## Install

First, add the theme plugin to your dependencies:

```sh
# NPM
npm install --save @saucelabs/theme-github-codeblock

# Yarn
yarn add @saucelabs/theme-github-codeblock
```

## Usage

Add the theme plugin to your list of themes in the `docusaurus.config.js`:

```js
    // ...
    themes: [
        '@saucelabs/theme-github-codeblock'
    ],
    // ...
```

In order to reference GitHub snippets in your markdown, create code blocks with a `reference` attached to the language meta string and put the link to your GitHub reference in the code block, e.g.:

    ```js reference
    https://github.com/saucelabs/docusaurus-theme-github-codeblock/blob/main/src/theme/ReferenceCodeBlock/index.tsx#L105-L108
    ```

You can also set a custom title:

    ```js reference title="Example"
    https://github.com/saucelabs/docusaurus-theme-github-codeblock/blob/main/src/theme/ReferenceCodeBlock/index.tsx#L105-L108
    ```

The plugin will download the code and display the desired lines:

![Plugin Example](https://github.com/saucelabs/docusaurus-theme-github-codeblock/raw/main/.github/assets/example.png 'Plugin Example')

---

If you are interested contributing to this project, see [CONTRIBUTING.md](CONTRIBUTING.md).
npm package: @roie.fink/pie-chart
Description: [![version](https://img.shields.io/npm/v/@nivo/pie.svg?style=flat-square)](https://www.npmjs.com/package/@nivo/pie)
Author: Roie Finkelshtein
Latest version: 1.0.2

# `@nivo/pie`

[![version](https://img.shields.io/npm/v/@nivo/pie.svg?style=flat-square)](https://www.npmjs.com/package/@nivo/pie)

## Pie

[documentation](http://nivo.rocks/pie)

![Pie](https://raw.githubusercontent.com/plouc/nivo/master/packages/pie/doc/pie.png)
npm package: @roimaswap/sdk
Description: 🛠 An SDK for building applications on top of pancakeswap.
Latest version: 3.0.5

# 🍚 Rice SDK

[![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square)](https://github.com/prettier/prettier)
[![Actions Status](https://github.com/pancakeswap/pancakeswap-sdk/workflows/CI/badge.svg)](https://github.com/pancakeswap/pancakeswap-sdk)
[![npm version](https://img.shields.io/npm/v/@pancakeswap-lib/sdk/latest.svg)](https://www.npmjs.com/package/@pancakeswap-lib/sdk/v/latest)

## Running tests

To run the tests, follow these steps. You must have at least node v10 and [yarn](https://yarnpkg.com/) installed.

First clone the repository:

```sh
git clone https://github.com/pancakeswap/pancakeswap-sdk.git
```

Move into the pancakeswap-sdk working directory

```sh
cd pancakeswap-sdk/
```

Install dependencies

```sh
yarn install
```

Run tests

```sh
yarn test
```

You should see output like the following:

```sh
yarn run v1.22.4
$ tsdx test
 PASS  test/constants.test.ts
 PASS  test/pair.test.ts
 PASS  test/fraction.test.ts
 PASS  test/miscellaneous.test.ts
 PASS  test/entities.test.ts
 PASS  test/trade.test.ts

Test Suites: 1 skipped, 6 passed, 6 of 7 total
Tests:       3 skipped, 82 passed, 85 total
Snapshots:   0 total
Time:        5.091s
Ran all test suites.
✨  Done in 6.61s.
```
npm package: @roimaswap/uikit
Description: Set of UI components for pancake projects
Latest version: 0.1.4

# 🥞 Pancake UIkit

[![Version](https://img.shields.io/npm/v/@pancakeswap-libs/uikit)](https://www.npmjs.com/package/@pancakeswap-libs/uikit) [![Size](https://img.shields.io/bundlephobia/min/@pancakeswap-libs/uikit)](https://www.npmjs.com/package/@pancakeswap-libs/uikit)

Pancake UIkit is a set of React components and hooks used to build pages on Pancake's apps. It also contains a theme file for dark and light mode.

## Install

`yarn add @pancakeswap-libs/uikit`

## Setup

### Theme

Before using Pancake UIkit, you need to provide the theme file to styled-component.

```
import { ThemeProvider } from 'styled-components'
import { light, dark } from '@pancakeswap-libs/uikit'
...
<ThemeProvider theme={isDark}>...</ThemeProvider>
```

### Reset

A reset CSS is available as a global styled component.

```
import { ResetCSS } from '@pancakeswap-libs/uikit'
...
<ResetCSS />
```

### Types

This project is built with Typescript and export all the relevant types.

## How to use the UIkit

If you want to use components from the UIkit, check the [Storybook documentation](https://pancakeswap.github.io/pancake-uikit/)
npm package: @roine/dict
Description: Dict for real data
Author: Jonathan de Montalembert
Latest version: 3.0.0

[![Build Status](https://travis-ci.org/roine/Dict.js.svg?branch=master)](https://travis-ci.org/roine/Dict.js)

# Dict.js

## Introduction
Inspired by [Elm][elm] `Dict`, Dict simplifies the access and manipulation to array of objects. 
Dict.js does not mutate the collection instead it returns a new collection.


## Installation
```bash
npm install @roine/dict --save
```
## Usage
If you have a data collection shape like follow (array of object with a unique identifier), keep reading:
```javascript
const games = [
  { id: "12245", title: "Bloody Roar" },
  { id: "12459", title: "The unholy war" },
];
```
You will most likely need to read/update it, you could use filter/reduce/find for the millionth
time. Or you could use `Dict`

### Insert
```javascript
const gameDict = Dict.fromArray(games)
gameDict.insert({ id: "12998", title: "Rival schools" });

gameDict.toArray() 
// returns
[
  { id: "12245", title: "Bloody Roar" },
  { id: "12459", title: "The unholy war" },
  { id: "12998", title: "Rival schools" }
];
```
Insert doesn't just append a new entry, if an entry with the same `id` is found it replaces that entry
```javascript
gameDict.insert({ id: "12245", title: "Sould Calibur" });

gameDict.toArray() 
//returns
[
  { id: "12245", title: "Sould Calibur" },
  { id: "12459", title: "The unholy war" },
  { id: "12998", title: "Rival schools" }
];
```

### Update
Great, but what if you want to update part of an entry instead
```javascript
gameDict.update("12245", entry => ({ ...entry, developer: "Bandai Namco Studios" }));

gameDict.toArray() 
// returns
[
  { id: "12245", title: "Sould Calibur", developer: "Bandai Namco Studios" },
  { id: "12459", title: "The unholy war" },
  { id: "12998", title: "Rival schools" }
];
```
We might also want to update an entry if found otherwise do nothing
```javascript
gameDict
  .update("12459", entry => {
    if (entry) {
      return { ...entry, developer: "Toys for Rob" };
    } else {
      return entry;
    }
  })
  .update("non-existent", entry => {
    if (entry) {
      return { ...entry, developer: "EA Games" };
    } else {
      return entry;
    }
  });

gameDict.toArray() 
// returns
[
  { id: "12245", title: "Sould Calibur", developer: "Bandai Namco Studios" },
  { id: "12459", title: "The unholy war", developer: "Toys for Rob" },
  { id: "12998", title: "Rival schools" },
];
```

### Remove
You can also remove an entry:
```javascript
gameDict.remove("12245")

gameDict.toArray() 
// Returns
[
  { id: "12459", title: "The unholy war", developer: "Toys for Rob" },
  { id: "12998", title: "Rival schools" }
];
```

### get
You need to read a specific entry? Use get.
```javascript
gameDict.get("12459")
// Returns 
{ id: "12459", title: "The unholy war", developer: "Toys for Rob" }
```
Easy, right!

[elm]: http://elm-lang.org/