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

@priyanshukr13/pitchdeck

v1.1.0

Published

Deterministic layout and shape builder library for professional PowerPoint presentations

Readme

pitchdeck

Deterministic layout engine & visual presentation builder for PowerPoint presentations.

pitchdeck is an opinionated TypeScript presentation generator built on top of pptxgenjs and Flexbox (yoga-layout). It replaces manual coordinate calculation and plain text boxes with executive-grade shape aesthetics, automatic typography scaling, and design DNA resolution.


Features

  • 🎨 11 Implemented Slide Archetypes: titleSlide, agendaSlide, sectionDividerSlide, bulletSlide, comparisonSlide, resultsSlide, statGrid, processSteps, diagramSlide, screenshotSlide, referencesSlide.
  • 📊 System & Architecture Diagrams: Flowcharts with decision branches, Entity-Relationship (ER) database schemas with attribute cards, Microservices Component Architectures, and Sequence diagrams.
  • 🖼️ Multi-Provider Stock Asset Engine: Integrated support for Unsplash (photos), Pexels (photos), Pixabay (vectors, illustrations, photos), and Freepik (vectors, icons) with unified caching and automatic fallback.
  • 📐 Yoga Flexbox Engine: Deterministic spatial layout calculation without hand-picking coordinates.
  • Built-in Modern Visual Hierarchy: Rounded container cards (roundRect), 4px primary left accent strips, category tag pills, vector step connectors, solid header banners, and title divider lines.
  • 🎯 fromSpec() Pipeline: Declaratively map mandated section lists to slide archetypes in a single call.
  • 🔍 Strict Validation Engine: Catches text overflows, contrast violations, overlapping elements, and min-gap collisions before saving.

Installation

npm install pitchdeck pptxgenjs yoga-layout-prebuilt

Quick Start

import { create } from 'pitchdeck';

// 1. Initialize builder with a content profile and optional stock provider keys
const deck = create({
  profile: { domain: 'systems', tone: 'technical', density: 'normal' },
  stockKeys: {
    unsplashKey: process.env.UNSPLASH_ACCESS_KEY,
    pexelsKey: process.env.PEXELS_API_KEY,
    pixabayKey: process.env.PIXABAY_API_KEY,
    freepikKey: process.env.FREEPIK_API_KEY,
  },
});

// 2. Build slides declaratively
deck
  .titleSlide({
    variant: 'formal-college',
    title: 'VoCall: India-First Voice Agent Builder',
    subtitle: 'Autonomous Multilingual Conversational AI',
    groupNumber: 'Group CS-14',
    supervisorName: 'Dr. Sandeep Kumar',
    institutionName: 'GNIOT College of Engineering',
  })
  .agendaSlide({
    sections: ['System Architecture', 'Database Schema', 'Results'],
  })
  // Flowchart Diagram
  .diagramSlide({
    title: 'Inbound Audio Stream Processing',
    diagramType: 'flowchart',
    nodes: [
      { id: 'start', label: 'SIP Inbound', shape: 'ellipse' },
      { id: 'auth', label: 'Validate Token', shape: 'diamond' },
      { id: 'stream', label: 'Audio Ingestion', shape: 'roundRect' },
      { id: 'asr', label: 'ASR Inference', shape: 'roundRect' },
    ],
    edges: [
      { from: 'start', to: 'auth', label: 'SIP INVITE' },
      { from: 'auth', to: 'stream', label: 'Valid' },
      { from: 'stream', to: 'asr', label: 'Opus Frames' },
    ],
  })
  // Entity-Relationship (ER) Diagram
  .diagramSlide({
    title: 'Database Schema (ER Diagram)',
    diagramType: 'er',
    nodes: [
      {
        id: 'USERS',
        label: 'Users Table',
        attributes: [
          { name: 'user_id', type: 'UUID', isPrimary: true },
          { name: 'email', type: 'VARCHAR(255)' },
          { name: 'org_id', type: 'UUID', isForeign: true },
        ],
      },
      {
        id: 'AGENTS',
        label: 'Voice Agents',
        attributes: [
          { name: 'agent_id', type: 'UUID', isPrimary: true },
          { name: 'user_id', type: 'UUID', isForeign: true },
          { name: 'prompt', type: 'TEXT' },
        ],
      },
    ],
    edges: [
      { from: 'USERS', to: 'AGENTS', cardinality: '1:N', label: 'provisions' },
    ],
  })
  // Component & Infrastructure Topology
  .diagramSlide({
    title: 'Microservices Topology',
    diagramType: 'component',
    groups: [
      { id: 'edge', label: 'Edge Layer' },
      { id: 'data', label: 'Persistence Layer' },
    ],
    nodes: [
      { id: 'client', label: 'Web Client', shape: 'user' },
      { id: 'gateway', label: 'API Gateway', shape: 'component', group: 'edge' },
      { id: 'db', label: 'PostgreSQL DB', shape: 'cylinder', group: 'data' },
    ],
    edges: [
      { from: 'client', to: 'gateway', label: 'HTTPS' },
      { from: 'gateway', to: 'db', label: 'TCP 5432' },
    ],
  });

// 3. Save presentation
await deck.save('output.pptx');

Stock Image & Vector Asset Integration

pitchdeck includes a unified multi-provider asset client supporting:

  • Unsplash: High-resolution photography with color tone matching.
  • Pexels: Curated photography and background visuals.
  • Pixabay: Photos, vector graphics (type: 'vector'), and illustrations.
  • Freepik: UI icons (type: 'icon'), vectors, and graphic assets.
const asset = await deck.fetchStockAsset({
  query: 'cloud database server',
  type: 'vector', // 'photo' | 'vector' | 'illustration' | 'icon'
  provider: 'pixabay', // optional specific provider
  fallbackProviders: ['freepik', 'unsplash', 'pexels'],
});

console.log(asset.url, asset.mimeType, asset.data.length);

License

MIT © Priyanshu