npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@epicdm/flowstate-collections

v1.1.1

Published

Shared RxDB collections for Epic Flow applications

Downloads

212

Readme

@epic-flow/collections

Shared RxDB collections for Epic Flow applications.

Overview

This package provides TypeScript type definitions and RxDB collection schemas for all data models used across the Epic Flow ecosystem. It includes comprehensive documentation for:

  • Project Management: Tasks, Projects, Milestones, Goals, Time Entries
  • Business Operations: Clients, Contacts, Opportunities
  • Financial Data: YNAB integration for Accounts, Budgets, Categories, Transactions
  • System Data: Organizations, Users, Workspaces, Codebases, Sessions
  • Conversations: Message handling, conversation state, AI interactions
  • Content: Documents, Templates, Discussions, Approvals

Installation

yarn add @epic-flow/collections

Usage

Import collection definitions and types:

import {
  TaskCollection,
  TaskModel,
  ProjectCollection,
  ProjectModel,
  collections
} from '@epic-flow/collections';

// Use individual collection
const taskCollection = TaskCollection;

// Or use collections object
const allCollections = collections;

Documentation

Comprehensive API documentation is generated using TypeDoc and typedoc-plugin-markdown.

Generating Documentation

# Generate HTML documentation
yarn docs

# Generate Markdown documentation
yarn docs:md

# Generate both HTML and Markdown
yarn docs:all

# Watch mode for development (HTML)
yarn docs:watch

# Watch mode for development (Markdown)
yarn docs:md:watch

Documentation Formats

HTML Documentation (docs/)

Interactive HTML documentation with:

  • Interface Documentation: All model interfaces with property descriptions
  • Type Definitions: Supporting types and enums
  • Collection Exports: RxDB collection configurations
  • Utility Functions: Helper functions like createId()
  • Search Functionality: Full-text search across all documentation
  • Dark Mode Support: Automatic theme switching

Viewing HTML Docs:

# On macOS
open docs/index.html

# On Linux
xdg-open docs/index.html

# Or use a local server
npx serve docs

Markdown Documentation (docs-md/)

Markdown documentation for:

  • GitHub/GitLab Integration: Renders natively in repository viewers
  • Static Site Generators: Compatible with VitePress, Docusaurus, MkDocs, etc.
  • Version Control: Easier to track changes in git diffs
  • Offline Reading: No web server required

Structure:

  • docs-md/README.md - Main index with all types
  • docs-md/interfaces/ - Individual interface documentation (44 files)
  • docs-md/type-aliases/ - Type alias documentation (7 files)

Viewing Markdown Docs:

# View main index
cat docs-md/README.md

# View specific interface
cat docs-md/interfaces/TaskModel.md

# Or open in your favorite markdown viewer
open docs-md/README.md

Key Features

Multi-Tenant Architecture

All collections include orgId for organization-level data isolation in multi-tenant applications.

Timestamp Management

Collections automatically manage createdAt and updatedAt timestamps with maxLength constraints for RxDB compatibility.

Composite Indexes

Optimized queries with composite indexes on frequently accessed field combinations:

indexes: [
  ['orgId', 'createdAt'],
  ['userId', 'createdAt']
]

Rich Metadata Support

Many collections include flexible metadata fields for extensibility:

  • Tasks: MCP agent execution, conversation state, time tracking
  • Projects: Planning data, file references, requirement tracking
  • Milestones: Acceptance criteria, file tracking
  • Messages: Tool calls, AI provider metadata

YNAB Financial Integration

Full support for You Need A Budget (YNAB) financial data:

  • Account management
  • Budget tracking
  • Category organization
  • Transaction and scheduled transaction sync

Collection Schemas

All collections use RxDB schema format with:

  • Version management (currently version 0)
  • Primary keys (typically id)
  • JSON Schema validation
  • Required fields enforcement
  • Custom hooks via defaultHooks()

Development

# Type checking
yarn typecheck

# Build package
yarn build

# Run tests
yarn test

# Generate documentation
yarn docs

Schema Versioning

Collections are currently at version 0. When making breaking schema changes:

  1. Increment the version number
  2. Add migration strategies if needed
  3. Update documentation

Contributing

When adding or modifying collections:

  1. Add JSDoc comments to all interfaces and properties
  2. Include metadata interfaces if the collection supports extensibility
  3. Define composite indexes for common query patterns
  4. Export types from src/index.ts
  5. Regenerate documentation with yarn docs
  6. Verify build with yarn build

License

ISC

Author

Epic Digital Interactive Media LLC