open-index/open-npm huggingface dataset:
npm package: @nate7611/calculator
Description: A simple command-line calculator that performs basic arithmetic operations.
Author: Nate Downey
Latest version: 1.0.0

# Calculator CLI

A simple command-line calculator that performs basic arithmetic operations.

## Overview

This project provides a command-line calculator that supports the following **8** operation keywords:

*   Addition (`add`)
*   Subtraction (`subtract`)
*   Multiplication (`multiply` or `times`)
*   Division (`divide`)
*   Modulus (`modulus` or `remainder`)
*   Power (`power`)

## Prerequisites

This project requires [Node.js](https://nodejs.org/) to be installed on your system. We recommend using Node.js version 12 or higher.


## Installation

1.  Install as a devDependencies:

    ```bash
    npm install @nate7611/calculator --save-dev
    ```


## Usage

To use the calculator, run the script with three arguments:

```bash
npx calculator.js number operator number
```

Examples:

*   Addition:

    ```
    node calculator.js 2 add 3
    // Expected Output: result: 5
    ```

*   Division:

    ```
    node calculator.js 10 divide 2
    // Expected Output: result: 5
    ```

*   Power:

    ```
    node calculator.js 2 power 3
    // Expected Output: result: 8
    ```


## License

This project is licensed under the MIT License. See the `LICENSE` file for more details.
npm package: @nate7611/financial-calculator
Description: A simple command-line financial calculator that processes transaction amounts and computes key financial metrics.
Author: Nate Downey
Latest version: 1.0.0

# Financial Calculator CLI

## Overview

This project provides a command-line financial calculator that processes a list of transaction amounts and outputs key financial metrics. The calculator computes the total number of transactions, total sum, average transaction value, total income (sum of positive transactions), total expenses (sum of negative transactions), and net balance.

## Prerequisites

This project requires Node.js (version 12 or higher). Please ensure that Node.js is installed on your system.

## Installation

To install the package as a development dependency, run:

npm install @nate7611/financial-calculator --save-dev

## Usage

To run the financial calculator, use the following command with a list of transaction amounts (ignoring non-numbers):

node financialCalculator.js <transaction1> <transaction2> ...

Example:

node financialCalculator.js 100 -50 job 200 taxes -75

## License

This project is licensed under the MIT License. See the LICENSE file for additional details.
npm package: @nateabele/use-app-state
Description: A React state management library using events and immutable data operations
Author: Nate Abele
Latest version: 0.2.0

# @nateabele/use-app-state

A React state management library using immutable event-based updates powered by Ramda.

## Installation

```bash
npm install @nateabele/use-app-state
```

## Usage

### Basic Hook Usage

```tsx
import { useAppState, Events } from '@nateabele/use-app-state';

function App() {
  const [state, emit] = useAppState({
    user: { name: '', email: '' },
    items: []
  });

  return (
    <div>
      <input
        value={state.user.name}
        onChange={e => emit(Events.set(['user', 'name'], e.target.value))}
      />
      <button onClick={() => emit(Events.append(['items'], { id: Date.now() }))}>
        Add Item
      </button>
    </div>
  );
}
```

### Scoped Emitters

Emitters can be scoped to a path, making nested components cleaner:

```tsx
function UserForm({ emit }) {
  const scopedEmit = emit.scope(['user']);

  return (
    <input onChange={e => scopedEmit(Events.set(['name'], e.target.value))} />
  );
}
```

### Configuration Options

```tsx
const [state, emit, controls] = useAppState(initialState, {
  log: true,           // Log all events to console
  expose: 'appState',  // Expose state to window.appState for debugging
  onEvent: (event, before, after) => {
    // Subscribe to all state changes
  }
});
```

## Events

| Event | Description | Example |
|-------|-------------|---------|
| `Events.set(path, value)` | Set a value at path | `Events.set(['user', 'name'], 'John')` |
| `Events.merge(path, obj)` | Merge object at path | `Events.merge(['user'], { name: 'John' })` |
| `Events.append(path, value)` | Append to array | `Events.append(['items'], newItem)` |
| `Events.push(path, index, value)` | Insert at index | `Events.push(['items'], 0, newItem)` |
| `Events.pull(path, index, count?)` | Remove from array/object | `Events.pull(['items'], 2, 1)` |
| `Events.drop(path, key)` | Remove key from object | `Events.drop(['user'], 'tempField')` |
| `Events.batch(events[])` | Batch multiple events | `Events.batch([...])` |
| `Events.noOp` | No operation | `Events.noOp` |

## Alternative: Non-Hook Initialization

For apps that need direct control over rendering:

```tsx
import { init } from '@nateabele/use-app-state';

const app = init(App, document.getElementById('root'), initialData);

app.onEvent((event, before, after) => {
  console.log('State changed:', event.name);
});

app.render();
```

## License

MIT