open-index/open-npm huggingface dataset:
npm package: @spacells/core
Description: Spacells - micro life for your virtual world
Latest version: 0.0.3

# Spacells - bacteria life simulation project

Inspired by the project [Hello Worlds - Virtual javascript worlds at planetary scales](https://github.com/kenjinp/hello-worlds), Spacells is a simulation library that brings micro life to your virtual world. It introduces the concept of bacteria cultures that can occupy areas, grow, consume resources, reproduce, compete and make decisions. Most of the features follow the principles of real life bacteria, but can be simplified or extended to make it more fun. The scientific papers in the area of cell biology or computer science will be mentioned in the documentation when more sophisticated methods are used in the simulation. Simulations are based on steps, where each one is a turn in which the system analyzes the conditions and changes its state. The library is written in Typescript and can be used in javascript projects. If you are interested in creating a virtual world with bacteria, this library is for you!

Next-gen organisms are coming! If the simulations prove to be useful, the library will be extended to support more complex organisms like plants, animals, and even civilizations.

## PoC phase

The project is in the early development stage and is not ready for production use. The API is not stable and can change at any time.

## Current features

- Bacteria has position and can be observed
- Bacteria consumes resources
- Bacteria migrates to look for resources
- Bacteria grows
- Bacteria reproduces

## Planned features

- Bacteria has reporoductive strategy
- Bacteria communicates via signals

## Ideas

- Bacteria fights the other bacteria
- Bacteria cooperates with others
- Mutagens in the environment can change bacteria features

## Setup

- `make install` - install dependencies
- `make build` - build the project
- `make test` - run tests

## Usage

```javascript
import { CellFactory, Simulation, TerrainFactory, generateIds } from "@spacells/core";

const terrain = TerrainFactory.createTerrain({ width: 10, height: 10, resourcesPerSpot: 10 });
const cells = generateIds(100).map((id) => CellFactory.createCell(terrain, { id }));
const simulation = new Simulation(terrain, cells);

for (let i = 0; i < 10; i++) {
  simulation.step();
}
```
npm package: @spacelr/cli
Description: CLI tool for the Spacelr platform - deploy hosting sites and manage databases
Latest version: 0.1.6

# @spacelr/cli

> **Note:** Spacelr is currently under active development. APIs may change between releases.

CLI tool for the Spacelr platform — deploy hosting sites and manage databases.

## Installation

```bash
npm install -g @spacelr/cli
```

## Usage

```bash
spacelr <command> [options]
```

### Global Options

| Option | Description |
| --- | --- |
| `--api-url <url>` | Override API URL |
| `--token <token>` | Explicit auth token (CI mode) |
| `--json` | Output as JSON |
| `--verbose` | Verbose logging |

### Commands

| Command | Description |
| --- | --- |
| `login` | Authenticate with the Spacelr platform |
| `logout` | Remove stored credentials |
| `whoami` | Show current user info |
| `projects` | List available projects |
| `use` | Select the active project |
| `init` | Initialize a new project in the current directory |
| `deploy` | Deploy a hosting site |
| `db rules-deploy` | Deploy database rules |
| `db rules-pull` | Pull database rules |
| `db indexes-deploy` | Deploy database indexes |
| `db indexes-pull` | Pull database indexes |

## Quick Start

```bash
# Login to your account
spacelr login

# Select a project
spacelr use

# Initialize and deploy
spacelr init
spacelr deploy
```

## Requirements

- Node.js >= 18

## License

MIT
npm package: @spacelr/sdk
Description: TypeScript SDK for the Spacelr API - auth and storage
Latest version: 0.1.5

# @spacelr/sdk

> **Note:** Spacelr is currently under active development. APIs may change between releases.

TypeScript SDK for the Spacelr API — authentication, storage, database and realtime notifications.

## Installation

```bash
npm install @spacelr/sdk
```

## Quick Start

```typescript
import { createClient } from '@spacelr/sdk';

const spacelr = createClient({
  apiUrl: 'https://api.your-domain.com',
  projectId: 'your-project-id',
  clientId: 'your-client-id',
});

// Login
const { user } = await spacelr.auth.login({
  username: 'user@example.com',
  password: 'password',
});

// Upload a file
await spacelr.storage.uploadFile({ file, path: '/images/photo.png' });

// Subscribe to database changes
spacelr.db.subscribe('my-collection', {
  onChange: (event) => console.log('changed:', event),
});
```

## Modules

| Module | Description |
| --- | --- |
| `auth` | Login, registration, OAuth2 PKCE flow, token management, 2FA |
| `storage` | File upload (including multipart), download, sharing, quota |
| `db` | Database operations with realtime subscriptions via WebSocket |
| `notifications` | Web Push notification subscription management |

## Requirements

- Node.js >= 18
- TypeScript >= 5 (recommended)

## License

MIT
npm package: @spacelys/cockpit
Description: Library for inputs for web based clients
Latest version: 0.2.2

# Cockpit
Input utility for browsers that interacts with mouse, keyboard, microphone, and gamepads

## Installation and Usage

`npm install @spacelys/cockpit --save`

### Keyboard Inputs

```typescript
import * as cockpit from '@spacelys/cockpit'

// creates a keyboard listener around the entire html document
// alternatively you could select a specific html element with document.querySelect()
const keyInputs = cockpit.keys(document);

keyInputs.subscribe((input: cockpit.KeyInput) => {
    if (input.key === "a") {
        console.log(`[a] has been held ${input.dt} since last update
                    [a] has been held ${input.held} total time`);
    }
});
```

### Mouse Inputs

```typescript
import * as cockpit from '@spacelys/cockpit'

// creates a mouse listener around a specific html element
const mouseInput = cockpit.mouse("#elementToCaptureInputsAt");

mouseInput.subscribe((input: cockpit.KeyInput) => {
  switch (input.type) {
    case "press":
      console.log(`pressed button ${input.button} @ (${input.pos.x}, ${input.pos.y})`);
      break;
    case "drag":
      console.log(`dragging with button ${input.button} @ (${input.pos.x}, ${input.pos.y})`);
      break;
    case "release":
      ...
  }
});
```

### Gamepad Inputs (Experimental)

Gamepad inputs are a little bit more interesting.  Unlike the keyboard or mouse input, we have to wait for a gamepad to connect, thus the async await call.  This call will time out after 2 seconds if no gamepads are connected (feel free to call again as many times to keep checking for a gamepad connection)

#### Connecting + Button Mapping

While by default we always connect you to the 0th gamepad, with a default buttonMapping setting.  You might run into a scenario where you have multiple gamepads where one doesnt use the w3 standard for gamepad inputs.

`gamepad.connectToGamePad(3, 1)`

The line above connects the user to the third gamepad.  With the mapping settings of 1 (0 is the default value for the default w3 mapping).

To get the list of potential gamepad connections call `gamepad.getGamePads()` which returns an array of connected gamepads with id and name.

```typescript
import * as cockpit from '@spacelys/cockpit'

// creates a gamepad listener that polls for inputs ever 50ms if a gamepad eventually connects
const gamepad = await cockpit.gamepad(50);

// if multiple gamepads are connected, use this to connect to the ith gamepad (0, 1, ..ith)
gamepad.connectToGamePad(1); // (optional)
gamepad.obs.subscribe((input: cockpit.GamePadInput) => {
    // listen in for gamepad events and react accordingly
});

```

---

## Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

## License

[MIT](https://choosealicense.com/licenses/mit/)
npm package: @spacelys/drawkit
Description: Library for rendering 2d elements onto a canvas
Latest version: 0.4.1

# Drawkit
Library for rendering 2d elements onto an html canvas

## Usage and Instalation

`npm install @spacelys/drawkit --save`

If you are using typescript autocomplete will be your best friend when it comes to understanding what methods to use when drawing rects, circles, sprites, text, etc...

### Drawing a square

```typescript
import * as drawkit from '@spacelys/drawkit'

const ctx = drawkit.CanvasBuilder('#myCanvasId');
ctx.primitive().rect()
    .at(0, 0)
    .size(64, 64)
    .color('rgb(255, 0, 0)')
    .render();
```

---

### Drawing multiple squares

```typescript
const squareStamp = ctx.primitive().rect()
    .size(64, 64)
    .color('rgb(255, 0, 0)');
    
[0, 128, 256, 512].forEach(x => {
    squareStamp
        .at(x, 0)
        .render();
});
```

---

### Drawing sprite

```typescript
import * as drawkit from '@spacelys/drawkit'

const ctx = drawkit.CanvasBuilder('#myCanvasId');
const mySprite = await drawkit.loadImage('./url/to/mySprite.png');

ctx.draw(mySprite)
    .at(200, 200)
    .scaled(2, 2)
    .part(0, 0, 16, 16)
    .render();
```

## Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

## License

[MIT](https://choosealicense.com/licenses/mit/)
npm package: @spacelys/randish
Description: Generates random values... sorta...
Latest version: 0.2.0

# Randish

## Basic Overview

Generate random values... Sorta...  Randish provides the ability to generate random values in a predictable manner.  While this sounds like an oximoron, this allows us to create functions that benefit from randomness without worrying about side effects.

## Installation and Usage

`npm install @spacelys/randish --save`

### Seeds

We use randish by generating a seed.  The value of the seed determines the sequence of values we will pull out of it.

```typescript
import { Seed } from '@spacelys/randish'

const seed = new Seed(12345);
```

### Basic Functions

```typescript
const seed = new Seed(12345);
// returns random Integer between 0 and 100
seed.randInt(0, 100);

// returns random Float between 0 and 100
seed.randFloat(0, 100);

// returns boolean, 50% of it being true
seed.randBool();

// returns boolean, 90% of it being true
seed.randBool(.9);
```

### Operations

The Nth operation since the creation of your seed is always guaranteed to give you the same value.  This implies that any subsequent runs of your applications will always return the same sequence of values.

```typescript
const seed1 = new Seed(54321);
seed1.randInt(0, 32);
seed1.randInt(0, 32);
const thirdOp = seed1.randInt(0, 32);

const seed2 = new Seed(54321);
seed2.randBool();
seed2.randBool();
console.log(thirdOp === seed2.randInt(0, 32)); // true
```

### Random Arrays

Use randArray to create an array of predefined length with random elements.  All the basic functions work with randArray.

```typescript
// an array creator that will create an array of 16 elements
const seedArray = seed.randArray(16);

// returns a new array of size 16 with integer elements between 5 and 10
seedArray.randInt(5, 10);
```

### Random Object

Use randObject to create an object that leverages some of the basic functions.  We have to extract some of the basic functions made accessible from the package in order to leverage their functionality.

```typescript
import { Seed, randInt } from '@spacelys/randish'

const seed = new Seed(12345);
const myNewObj = seed.randObject({
  name: 'blue-blob',
  hp: randInt(50, 100)
}); // myNewObj = { name: 'blue-blob', hp: 64 }
```

## Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure the changes in the Pull Request pass the cloud build checks setup.  Merges to master will automatically publish NPM package.  Ensure that the version number is correct before merging your PR into master as that is the version number the package will be published with.
npm package: @spacemadev/tailstore4
Description: A modern landing page template built with Tailwind CSS
Author: spacemadev
Latest version: 1.0.0

![Tailstore Template](https://spacema-dev.com/tailstore/fullimage.png)

# Tailstore v4 – Free Tailwind CSS 4 eCommerce Template
Tailstore v4 is a modern, responsive eCommerce template built with Tailwind CSS v4 — a major upgrade from the popular v3 version. Tailstore helps developers and small businesses launch elegant online stores faster than ever. This is one of the first free templates publicly available using Tailwind CSS v4, ideal for anyone looking to build with the latest tools and utility classes.

🔗 Check out the demo of Tailstore template [here](https://spacema-dev.com/tailstore/).

# Key Features (v4)
## Main Page
Swiper Slider: Feature trending products or promos with a smooth, mobile-friendly slider.

Brand Carousel: Display trusted brand logos to build customer trust.

Latest & Popular Products: Engage visitors with updated product lists.

Blog Section: Boost SEO and engagement with a clean, integrated blog.

Email Subscription Form: Grow your list with a responsive, styled form.

## Shop Pages
Product Filters: Let users filter by category, price, and more.

Clean Product Listings: Optimized for readability and conversions.

Detailed Product Page:

High-quality product images

Tabbed product information

Customer reviews

Social sharing buttons

## Additional Pages
Shopping Cart: With coupon code support and quantity adjustment.

Checkout Page: Clean layout to reduce friction during payment.

Login / Register Pages: Basic user auth interface included.

404 Page: Custom error page for better UX.

Sticky Header with Cart Module: Persistent cart access for better usability.

#  What's New in Tailstore v4
Rebuilt from the ground up using Tailwind CSS v4

Clean, optimized CSS output using the latest CLI tools

Responsive design powered by new utility-first classes

No config file required for basic use – minimal setup!

# Installation
## 1. Clone the repository
```
git clone https://github.com/spacemadev/tailstore4.git
cd tailstore4
```

## 2. Install dependencies
```
npm install
```

## 3. Start the development server
```
npm run dev
```

## 4. Build for production
```
npm run build
```


# License
This template is released under the MIT License – free to use, modify, and distribute.

# Support & Contribution
If you like this project, please ⭐ it and share with others!
Feel free to fork or contribute via pull requests.

### Images:

Some images used in this template are designed by Freepik. You can find more of their work at [Freepik](https://www.freepik.com/).