open-index/open-npm huggingface dataset:
npm package: @ronin/three
Description: JavaScript 3D library
Author: mrdoob
Latest version: 0.180.0

# three.js

[![NPM Package][npm]][npm-url]
[![Build Size][build-size]][build-size-url]
[![NPM Downloads][npm-downloads]][npmtrends-url]
[![Discord][discord]][discord-url]
[![DeepWiki][deepwiki]][deepwiki-url]

#### JavaScript 3D library

The aim of the project is to create an easy-to-use, lightweight, cross-browser, general-purpose 3D library. The current builds only include WebGL and WebGPU renderers but SVG and CSS3D renderers are also available as addons.

[Examples](https://threejs.org/examples/) &mdash;
[Docs](https://threejs.org/docs/) &mdash;
[Manual](https://threejs.org/manual/) &mdash;
[Wiki](https://github.com/mrdoob/three.js/wiki) &mdash;
[Migrating](https://github.com/mrdoob/three.js/wiki/Migration-Guide) &mdash;
[Questions](https://stackoverflow.com/questions/tagged/three.js) &mdash;
[Forum](https://discourse.threejs.org/) &mdash;
[Discord](https://discord.gg/56GBJwAnUS)

### Usage

This code creates a scene, a camera, and a geometric cube, and it adds the cube to the scene. It then creates a `WebGL` renderer for the scene and camera, and it adds that viewport to the `document.body` element. Finally, it animates the cube within the scene for the camera.

```javascript
import * as THREE from 'three';

const width = window.innerWidth, height = window.innerHeight;

// init

const camera = new THREE.PerspectiveCamera( 70, width / height, 0.01, 10 );
camera.position.z = 1;

const scene = new THREE.Scene();

const geometry = new THREE.BoxGeometry( 0.2, 0.2, 0.2 );
const material = new THREE.MeshNormalMaterial();

const mesh = new THREE.Mesh( geometry, material );
scene.add( mesh );

const renderer = new THREE.WebGLRenderer( { antialias: true } );
renderer.setSize( width, height );
renderer.setAnimationLoop( animate );
document.body.appendChild( renderer.domElement );

// animation

function animate( time ) {

	mesh.rotation.x = time / 2000;
	mesh.rotation.y = time / 1000;

	renderer.render( scene, camera );

}
```

If everything goes well, you should see [this](https://jsfiddle.net/w43x5Lgh/).

### Cloning this repository

Cloning the repo with all its history results in a ~2 GB download. If you don't need the whole history you can use the `depth` parameter to significantly reduce download size.

```sh
git clone --depth=1 https://github.com/mrdoob/three.js.git
```

### Change log

[Releases](https://github.com/mrdoob/three.js/releases)


[npm]: https://img.shields.io/npm/v/three
[npm-url]: https://www.npmjs.com/package/three
[build-size]: https://badgen.net/bundlephobia/minzip/three
[build-size-url]: https://bundlephobia.com/result?p=three
[npm-downloads]: https://img.shields.io/npm/dw/three
[npmtrends-url]: https://www.npmtrends.com/three
[discord]: https://img.shields.io/discord/685241246557667386
[discord-url]: https://discord.gg/56GBJwAnUS
[deepwiki]: https://deepwiki.com/badge.svg
[deepwiki-url]: https://deepwiki.com/mrdoob/three.js
npm package: @ronin_jjj/randomize
Description: Easily randomize values from a simple 50-50 percentage to more advanced percentages!
Author: Ronin_jjj
Latest version: 2.0.1

# randomize
Easily randomize values from a simple 50-50 percentage to more advanced percentages!

```ts
import randomize from "@ronin_jjj/randomize"

randomize({
    heads: 50, //50%
    tails: 50
}) // "heads" | "tails"

randomize({
    bronze: 70, //70%
    silver: 20,
    gold: 10
}) // "bronze" | "silver" | "gold"

randomize({
    fail: 60.4, // 60.4%
    succeed: 39.5, 
    jackpot: 0.1
}) // "fail" | "succeed" | "jackpot"
```
npm package: @roninbuilders/rns
Description: Small package to interact with RNS
Author: Glitch-txs
Latest version: 0.0.11

```sh
pnpm add @roninbuilders/rns
```

You can call the functions directly
```ts
import { getName, getAddr } from '@roninbuilders/rns'

const myRNS = await getName('MY_RONIN_ADDRESS')

const myAddress = await getAddr(myRNS)
```


Or instantiate an object with a fixed RPC url:
```ts
import { initRNS } from '@roninbuilders/rns'

const RPCUrl = '...'
const rns = initRNS(RPCUrl)

const myAddress = await rns.getAddr('myRNS.ron')

const myRNS = await rns.getName(myAddress)
```
npm package: @roninjin10/babel-plugin-sol
Description: A babel plugin for ts-sol
Latest version: 0.0.1

# babel-plugin-sol

A babel plugin for transpiling template string solidity from ts-sol

## Usage

### Install this package

_Currently not published to npm_

```bash
pnpm i @roninjin10/babel-plugin-sol
```

### Add to babel.config.js

```typescript
export default (api) => {
  return {
    plugins: ['@roninjin10/babel-plugin-sol'],
  }
}
```

### Now you can write solidity with ts-sol

ts-sol contains the code that runs at runtime

```bash
pnpm i @roninjin10/ts-sol
```

```typescript
import { run, tsSol } from '@roninjin10/ts-sol'
import { useState } from 'react'

const forgeScript = tsSol`
contract Script {
    function run() external returns (string memory) {
        return "Hello, World!";
    }
}
`
const sayHello = (): Promise<string> => run(forgeScript)
```
npm package: @roninjin10/balance-monitor
Description: [Optimism] Forta Agent that reports whether certain accounts have fallen below some balance
Author: Optimism PBC
Latest version: 0.0.3

# Minimum Balance Agent

## Description

A forta agent which detects when a specified account balance is below the
specified threshold.

## Installing and building

`yarn && yarn build`

## Running

1. Copy `.env.example` into `.env` and set the appropriate values.
2. Copy `forta.config.example.json` into `forta.config.json`, and set the RPC endpoint (yes, this is
   duplicated in the .env file).
2. `yarn run start:prod`

## Alerts

- `OPTIMISM-BALANCE-DANGER-[ACCOUNT_NAME]`
  - Fired when the specified account balance is below the configured DANGER threshold
  - Severity is always set to "high"
  - Type is always set to "info"
  - Metadata "balance" field contains amount of wei in account
npm package: @roninjin10/common-ts
Description: [Optimism] Advanced typescript tooling used by various services
Author: Optimism PBC
Latest version: 0.7.0

# @eth-optimism/common-ts

[![codecov](https://codecov.io/gh/ethereum-optimism/optimism/branch/develop/graph/badge.svg?token=0VTG7PG7YR&flag=common-ts-tests)](https://codecov.io/gh/ethereum-optimism/optimism)

## What is this?

`@eth-optimism/common-ts` contains useful tools for logging, metrics, and other Node stuff.
npm package: @roninjin10/contracts-periphery
Description: [Optimism] External (out-of-protocol) L1 and L2 smart contracts for Optimism
Author: Optimism PBC
Latest version: 1.0.6

# Optimism Peripheral Smart Contracts

[![codecov](https://codecov.io/gh/ethereum-optimism/optimism/branch/develop/graph/badge.svg?token=0VTG7PG7YR&flag=contracts-periphery-tests)](https://codecov.io/gh/ethereum-optimism/optimism)
npm package: @roninjin10/core-utils
Description: [Optimism] Core typescript utilities
Author: Optimism PBC
Latest version: 0.12.0

# @eth-optimism/core-utils

[![codecov](https://codecov.io/gh/ethereum-optimism/optimism/branch/develop/graph/badge.svg?token=0VTG7PG7YR&flag=core-utils-tests)](https://codecov.io/gh/ethereum-optimism/optimism)

## What is this?

`@eth-optimism/core-utils` contains the Optimistic Virtual Machine core utilities.

## Getting started

### Building and usage

After cloning and switching to the repository, install dependencies:

```bash
$ yarn
```

Use the following commands to build, use, test, and lint:

```bash
$ yarn build
$ yarn start
$ yarn test
$ yarn lint
```

### L2 Fees

`TxGasLimit` can be used to `encode` and `decode` the L2 Gas Limit
locally.

```typescript
import { TxGasLimit } from '@eth-optimism/core-utils'
import { JsonRpcProvider } from 'ethers'

const L2Provider = new JsonRpcProvider('https://mainnet.optimism.io')
const L1Provider = new JsonRpcProvider('http://127.0.0.1:8545')

const l2GasLimit = await L2Provider.send('eth_estimateExecutionGas', [tx])
const l1GasPrice = await L1Provider.getGasPrice()

const encoded = TxGasLimit.encode({
  data: '0x',
  l1GasPrice,
  l2GasLimit,
  l2GasPrice: 10000000,
})

const decoded = TxGasLimit.decode(encoded)
assert(decoded.eq(gasLimit))

const estimate = await L2Provider.estimateGas()
assert(estimate.eq(encoded))
```
npm package: @roninjin10/hardhat-deploy-config
Description: [Optimism] Hardhat deploy configuration plugin
Author: Optimism PBC
Latest version: 0.2.5

# @eth-optimism/hardhat-deploy-config

`hardhat-deploy-config` is a simple plugin that adds support for global deploy configuration values.

## Installation

```
yarn add @eth-optimism/hardhat-deploy-config
```