open-index/open-npm huggingface dataset:
npm package: @spiritswap-libs/sdk
Description: 🛠 An SDK for building applications on top of spiritswap.
Latest version: 1.0.1

# Pancakeswap 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: @spirobel/mininext
Description: To install
Latest version: 0.8.1

# mininext

To install

```bash
bun add @spirobel/mininext
```

syntax highlighting:

[mininext vs code extension](https://marketplace.visualstudio.com/items?itemName=spirobel.mini-next-vs-code)

github:

[mininext github repo](https://github.com/spirobel/mininext)

quickstart:

```bash
bun create spirobel/counter yournewproject
```

if you don't have bun installed, run first:

```bash
curl -fsSL https://bun.sh/install | bash # for macOS, Linux, and WSL
```

To install dependencies:

```bash
bun install
```

dev:

```bash
bun run --hot counter.ts
```

production:

```bash
NODE_ENV=production bun run counter.ts
```

## Tutorial

If you understand these 3 basic concepts you can build your own webapp with mininext:

1. html + css
2. templating
3. you can use data inside of your html templates
npm package: @spirobel/monero-wallet-api
Description: To install dependencies:
Latest version: 0.3.0

# @spirobel/monero-wallet-api

To install dependencies:

```bash
cd typescript || cd ../typescript
bun install
```

To build:

```bash
cd typescript || cd ../typescript
bun build
```

rust release build

```bash
cd rust || cd ../rust
cargo build  --target wasm32-wasip1 --release --lib
```

prerequisite: install rust

```bash
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
```

```bash
rustup install 1.89.0
rustup default 1.89.0
rustup target add wasm32-wasip1
```

## reproducible build with pinned cargo + rust + cargo wasi

make the image

```bash
cd rust || cd ../rust
docker build -t monero-wallet-api-build .
```

build the library -> find the result in target/wasm32-wasip1/release

```bash
docker run -v $(pwd):/app -it monero-wallet-api-build
```

```bash
cd typescript || cd ../typescript
bun run build
bun run inlinesum
```

if the content of the checksum.txt file stays the same, the build was reproduced.

to verify that the wasm file distributed on npm matches the checksum,
add the npm package as a dependency to a project and compare the sha256sum output with the checksum.txt file in the git repo.

```bash
cd /tmp
bun init
bun add @spirobel/monero-wallet-api
cat node_modules/@spirobel/monero-wallet-api/dist/wasmFile.js | sha256sum
```
npm package: @spirobel/seedphrase
Description: This package collects functions to generate wallet secrets from a bip39 seedphrase + wallet route + seedphrase offset passphrase.
Latest version: 0.1.1

# seedphrase

This package collects functions to generate wallet secrets from a bip39 seedphrase + wallet route + seedphrase offset passphrase.

The purpose is to help users keep their online identities compartmentalized.

## Usage

Most commonly used functions:

```ts
import {
  generateSeedphrase,
  getWalletSecret,
  validateSeedphrase,
  WALLET_DEFAULT_ROUTE,
  walletRouteToString,
} from "@spirobel/seedphrase";
```

For a full usage example see the onboarding dialogue implemented in the [monero browser wallet](https://github.com/monerochan-ecosystem/monerochan-city-wallet)

To install:

```bash
bun install @spirobel/seedphrase
```
npm package: @spissvinkel/dsl-parser
Description: A simple parser combinator library for expressions and domain specific languages, written in Typescript
Author: Simen Storsveen
Latest version: 0.1.3

# DSL Parser

A simple parser combinator library for expressions and domain specific languages, written in Typescript.


## API Documentation

[TSDoc API reference](https://spissvinkel.github.io/dsl-parser-ts/api/)


## Install dependencies

```bash
$ npm install
```


## Build project

Before first build:
```bash
$ mkdir dist
```
(Re)build:
```bash
$ ./build.sh
```


## References

This project was inspired by the paper "Monadic Parser Combinators" by Hutton and Meijer, the paper "Parsec: Direct Style Monadic Parser Combinators for the Real World" by Leijen and Meijer, and the chapter on parser combinators in the book "Programming in Scala" by Odersky et al.
npm package: @spissvinkel/maths
Description: Maths library for JS/TS
Author: Simen Storsveen
Latest version: 1.2.0

# maths-js

A small TypeScript/JavaScript library of mathematical functions, mainly vector and matrix utilities.


## Documentation

[TSDoc API reference](https://spissvinkel.github.io/maths-js/api/)


## Installation

As an npm package:

```bash
$ npm install @spissvinkel/maths
```


## Sample usage

Create a file `sample.ts`:

```typescript
// import a module
import * as vec2 from '@spissvinkel/maths/vec2';

// initialize a new vector object
const v = vec2.of(1.0, 1.0);

// normalise the vector
vec2.norm(v);

// output the result
console.log(`v = [ ${v.x} ${v.y} ]`);
```

Compile to JavaScript using the [TypeScript](https://github.com/Microsoft/TypeScript) compiler:

```bash
$ tsc sample.ts
```

Bundle with e.g. [Google Closure Compiler](https://github.com/google/closure-compiler):

```bash
$ google-closure-compiler                        \
    --process_common_js_modules=true             \
    --module_resolution=NODE                     \
    --js=node_modules/@spissvinkel/maths/*.js    \
    --js=sample.js                               \
    --js_output_file=out.js
```

Run the bundled code to see the result:

```bash
$ node out.js

v = [ 0.7071067811865475 0.7071067811865475 ]
```
npm package: @spissvinkel/simplex-noise
Description: Simplex noise generator for JS/TS
Author: Simen Storsveen
Latest version: 1.0.1

# simplex-noise-ts

A simplex noise generator written in Typescript.

This project is a fork of [https://github.com/jwagner/simplex-noise.js](https://github.com/jwagner/simplex-noise.js) modified for easier integration into other Typescript projects. It is originally a port of [this Java implementation](http://webstaff.itn.liu.se/~stegu/simplexnoise/SimplexNoise.java) by Stefan Gustavson and Peter Eastman


## Documentation

[TSDoc API reference](https://spissvinkel.github.io/simplex-noise-ts/api/)


## Installation

As an npm package:

```bash
$ npm install @spissvinkel/simplex-noise
```
npm package: @spithacode/game-loop
Description: Simple fixed timestamp based game loop.
Author: Sid Ali Assoul
Latest version: 1.0.2

# @spithacode/game-loop

A TypeScript game loop implementation with fixed timestep pattern, perfect for creating smooth and consistent game animations. This package provides a singleton game loop that maintains consistent update rates while allowing for variable rendering framerates.

## Features

- Fixed timestep updates for consistent game logic
- Variable rendering framerate
- FPS control (20-144 FPS)
- Singleton pattern for global state management
- Written in TypeScript with full type support
- Zero dependencies

## Installation

Using pnpm (recommended):

```bash
pnpm add @spithacode/game-loop
```

Using npm:

```bash
npm install @spithacode/game-loop
```

Using yarn:

```bash
yarn add @spithacode/game-loop
```

## Usage

```typescript
import { getGameLoop } from "@spithacode/game-loop";

// Get the game loop instance
const gameLoop = getGameLoop();

// Game state
let playerX = 0;
let playerY = 0;
const PLAYER_SPEED = 100; // pixels per second

// Update function - runs at fixed timestep
const update = (dt: number) => {
  // dt is in seconds
  playerX += PLAYER_SPEED * dt;
  playerY += PLAYER_SPEED * dt;
};

// Render function - runs as fast as possible
const render = () => {
  // Update your canvas or DOM here
  console.log(`Player position: (${playerX}, ${playerY})`);
};

// Start the game loop
gameLoop.start(update, render);

// Optionally set target FPS (default is 60)
gameLoop.setTargetFPS(144); // Values between 20-144 are supported

// Stop the loop when needed
// gameLoop.stop();
```

## API Reference

### `getGameLoop()`

Returns the singleton instance of the GameLoop class.

### `GameLoop` Class

#### Properties

- `time: number` - Get the total elapsed time since the game loop started

#### Methods

- `start(update: (dt: number) => void, render: () => void): void`

  - Starts the game loop
  - `update`: Function called at fixed intervals with delta time in seconds
  - `render`: Function called as often as possible for rendering

- `stop(): void`

  - Stops the game loop

- `setTargetFPS(fps: number): void`
  - Sets the target FPS for updates (between 20 and 144)

## Technical Details

The game loop uses a fixed timestep pattern which:

- Ensures consistent physics and game logic updates
- Prevents spiral of death in slow frames
- Separates update logic from rendering
- Maintains smooth animations even under varying system performance

Default values:

- Default FPS: 60
- Minimum FPS: 20
- Maximum FPS: 144

## License

MIT © [Sid Ali Assoul]

## Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

## Support

If you encounter any issues or have questions, please file an issue on the [GitHub repository](https://github.com/spithacode/game-loop/issues).
npm package: @spithacode/input-manager
Description: A package which abstract dealing with keyboard and mouse events for a given HTML element
Author: Sid Ali Assoul
Latest version: 1.0.4

# @spithacode/input-manager

A lightweight and efficient input management system for handling keyboard and mouse inputs for any HTML element in web applications.

## Features

- ⌨️ Keyboard input handling
- 🖱️ Mouse input management with position tracking
- 🎯 Event-based architecture
- 🔄 Real-time input state updates
- 📦 Modular and reusable design
- 🧹 Automatic cleanup and resource management
- 🎨 Works with any HTML element

## Installation

Using pnpm:

```bash
pnpm add @spithacode/input-manager
```

## Usage

### Basic Example

```typescript
import { InputManager } from "@spithacode/input-manager";

// Initialize the input manager with any HTML element
const targetElement = document.getElementById("your-element");
const inputManager = new InputManager(targetElement);

// Check if a key is pressed
if (inputManager.isKeyPressed("ArrowRight")) {
  // Handle right arrow key press
}

// Get mouse position relative to the element
const mousePos = inputManager.getMousePosition();
console.log(`Mouse position: x=${mousePos.x}, y=${mousePos.y}`);

// Check mouse button state
if (inputManager.isMouseButtonPressed(0)) {
  // Left mouse button
  // Handle left click
}

// Clean up when done
inputManager.destroy();
```

## API Reference

### InputManager Class

The main class that handles all input management. Can be used with any HTML element such as div, canvas, section, or any other valid HTML element.

#### Constructor

```typescript
constructor(element: HTMLElement)
```

- `element`: Any HTML element to attach input listeners to (div, canvas, section, etc.)

#### Methods

- `isKeyPressed(key: Key): boolean`

  - Check if a specific key is currently pressed
  - Returns `true` if the key is pressed, `false` otherwise

- `isMouseButtonPressed(button: MouseButton): boolean`

  - Check if a mouse button is pressed
  - Button values: 0 (left), 1 (middle), 2 (right)
  - Returns `true` if the button is pressed, `false` otherwise

- `getMousePosition(): MousePosition`

  - Get current mouse coordinates relative to the target element
  - Returns `{ x: number, y: number }`

- `reset(): void`

  - Reset all input states

- `destroy(): void`
  - Clean up event listeners and resources

## Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

1. Fork the repository
2. Create your feature branch (`git checkout -b feature/amazing-feature`)
3. Commit your changes (`git commit -m 'Add some amazing feature'`)
4. Push to the branch (`git push origin feature/amazing-feature`)
5. Open a Pull Request

## License

MIT © [Spithacode](https://github.com/spithacode)

## Author

- [Spithacode](https://github.com/spithacode)
- Website: [https://spithacode.com](https://spithacode.com)
npm package: @spjpgrd/inkwell
Description: A gorgeous, accessible color system based on Radix Colors
Author: sean patrick john paul george ringo doran
Latest version: 1.0.1

![Inkwell Logo](assets/spjpgrd-inkwell.jpg)

# Inkwell

**A gorgeous, accessible color system.**

Based on Radix Colors, modified and enhanced by Seán Doran.

---

## Features

- 🎨 100+ carefully crafted color palettes
- ♿ Accessible color combinations
- 🌙 Light and dark variants
- 📱 Alpha channel support
- 🎯 CSS custom properties
- 📦 TypeScript support
- 🚀 Zero runtime dependencies

## Installation

```bash
npm install @spjpgrd/inkwell
# or
yarn add @spjpgrd/inkwell
# or
pnpm add @spjpgrd/inkwell
```

## Usage

```typescript
import { amber, blue, gray } from '@spjpgrd/inkwell';

// Use the colors in your CSS
const styles = {
  backgroundColor: amber.amber9,
  color: gray.gray1,
  borderColor: blue.blue6,
};
```

## Documentation

For full documentation, visit [radix-ui.com/colors/docs](https://radix-ui.com/colors/docs).

## Authors

- Colm Tuite ([@colmtuite](https://twitter.com/colmtuite))
- Vlad Moroz ([@vladyslavmoroz](https://twitter.com/vladyslavmoroz))
- **Modified by Seán Doran ([@spjpgrd](https://www.spjpgrd.com))**

## License

MIT
npm package: @spkf/react-tabs
Description: Simple responsive tabs
Latest version: 1.0.8

# React Tabs

## Installation

Install `@spkf/react-tabs` using your preferred package manager:

### npm

```bash
npm install @spkf/react-tabs
```

### pnpm

```bash
pnpm add @spkf/react-tabs
```

### yarn

```bash
yarn add @spkf/react-tabs
```

### bun

```bash
bun add @spkf/react-tabs
```

## 🌐 Live Example and Documentation

Check out the live demo: [https://springkraf.github.io/react-tabs](https://springkraf.github.io/react-tabs)