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

@deina-labs/deina-core

v1.1.9

Published

Shared dating archetype logic for Deina — used by mobile, web app and edge functions

Readme

@deina-labs/deina-core

Shared dating archetype logic, quiz data, onboarding content, and coaching characters for the Deina ecosystem. Used by the mobile app (React Native/Expo), web app, and Supabase edge functions.

Zero runtime dependencies. Pure TypeScript data + logic.

Installation

Option 1: npm (recommended)

yarn add @deina-labs/deina-core

Option 2: GitHub dependency

In your consuming project's package.json:

{
  "dependencies": {
    "@deina-labs/deina-core": "github:joynOS/deina-core"
  }
}

Then run:

yarn install

Option 3: Local development (linking)

If you're working on deina-core alongside another project locally:

# In deina-core/
yarn install
yarn build

# In your consuming project/
yarn add link:../deina-core

Option 4: Supabase Edge Functions (Deno)

import { classifyArchetype, DATING_ARCHETYPES } from 'npm:@deina-labs/deina-core';

For the npm: specifier to work, the package must be published to npm or use an import map pointing to the GitHub dependency.

Build

yarn install
yarn build

This compiles src/ to dist/ with type declarations.

What's inside

| File | What it exports | |------|----------------| | types.ts | DatingArchetype, ArchetypeCoaching, UserPreferences interfaces | | archetypes.ts | DATING_ARCHETYPES — the 6 archetype definitions | | coaching.ts | ARCHETYPE_COACHING, buildArchetypeContext() — coaching directives per archetype | | classify.ts | classifyArchetype() — weighted scoring across all 5 quiz sections | | quiz-questions.ts | STANDARDS_QUALITIES, TIMELINE_QUESTIONS, MINDSET_QUESTIONS, ENFORCEMENT_QUESTIONS, TRADEOFF_QUESTIONS | | fun-facts.ts | ONBOARDING_FUN_FACTS, SECTION_HINTS — transition screen content | | onboarding-content.ts | DISCLAIMER_CONTENT, ABOUT_YOU_CONTENT, SECTION_INTROS (standards, timeline, mindset, tradeoffs, enforcement, players), ARCHETYPE_REVEAL_CONTENT, MEET_DEINA_CONTENT, CHOOSE_DEINA_CONTENT, ACCOUNT_CREATION_CONTENT | | deinas.ts | DEINA_CHARACTERS, getDeinaById() — 7 coaching characters | | archetype-card.ts | renderArchetypePage(), renderNotFoundPage() — HTML share card renderer |

Usage

Importing in React Native / Expo

import {
  DATING_ARCHETYPES,
  classifyArchetype,
  STANDARDS_QUALITIES,
  TIMELINE_QUESTIONS,
  MINDSET_QUESTIONS,
  ENFORCEMENT_QUESTIONS,
  TRADEOFF_QUESTIONS,
} from '@deina-labs/deina-core';

// Classify a user's archetype from their quiz answers
const archetype = classifyArchetype({
  standards: { physicalAttraction: 4, emotionalStability: 5, ... },
  timelineAnswers: { progressionPace: 'Structured and steady', ... },
  mindsetAnswers: { standardsConfidence: '4', ... },
  enforcementAnswers: { cancelDowngrade: '1 time', ... },
  tradeOffAnswers: { consistencyVsChemistry: 'Consistent effort even if chemistry builds slowly', ... },
});

console.log(archetype.name); // "The Strategic Dater"
console.log(archetype.signatureLine); // "You trust patterns more than promises."

Using onboarding content

import {
  DISCLAIMER_CONTENT,
  SECTION_INTROS,
  ABOUT_YOU_CONTENT,
} from '@deina-labs/deina-core';

// All screen copy is centralized — no hardcoded strings in your UI
<Text>{DISCLAIMER_CONTENT.heading}</Text>
<Text>{SECTION_INTROS.standards.body}</Text>

Coaching context for AI prompts

import { buildArchetypeContext } from '@deina-labs/deina-core';

const context = buildArchetypeContext('the-strategic-dater');
// Returns a formatted string with traits, pitfalls, and coaching directive
// ready to inject into a system prompt

Deina characters

import { DEINA_CHARACTERS, getDeinaById } from '@deina-labs/deina-core';

const deina = getDeinaById('blonde');
console.log(deina.name); // "Chloe"
console.log(deina.tone); // "The Optimistic Strategist"
console.log(deina.systemPromptModifier); // system prompt personality modifier

Share card HTML (edge functions)

import { renderArchetypePage, renderNotFoundPage } from '@deina-labs/deina-core';

// Returns a full HTML page string
const html = renderArchetypePage(archetype, 'Josephine');
const notFound = renderNotFoundPage();

Architecture

Mobile App (Expo)  ──┐
                     ├──> @deina-labs/deina-core (this package)
Web App            ──┤
                     │
Edge Functions     ──┘

All quiz logic, archetype data, coaching content, and onboarding copy lives here. Consumer apps only handle UI rendering and platform-specific concerns.

License

MIT