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

ngx-pro-editor

v1.3.3

Published

A powerful, fully custom Angular rich text editor with zero external editor dependencies. Supports rich text formatting, font controls, 80+ colors, background highlights, headings (H1–H6), blockquotes, code blocks, lists, alignment, and more. Modular and

Readme

NGX Pro Editor

npm version npm downloads License: MIT Angular Live Demo

A powerful, feature-rich WYSIWYG rich text editor for Angular — zero external editor dependencies.

🌐 Try the Live Demo →

📦 npm · 💻 GitHub · 🌐 Live Demo · 🐛 Issues


📦 Installation

npm install ngx-pro-editor

Add Material Icons and Inter font to your index.html:

<link href="https://fonts.googleapis.com/css2?family=Material+Icons+Round" rel="stylesheet">
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap" rel="stylesheet">

🚀 Quick Start

import { Component } from '@angular/core';
import { NgxProEditorComponent } from 'ngx-pro-editor';

@Component({
  selector: 'app-root',
  standalone: true,
  imports: [NgxProEditorComponent],
  template: `
    <ngx-pro-editor
      [config]="editorConfig"
      (save)="onSave($event)"
      (htmlChange)="onContentChange($event)">
    </ngx-pro-editor>
  `
})
export class AppComponent {
  editorConfig = {
    placeholder: 'Start typing...',
    minHeight: 400,
    autoSave: true,
    theme: 'dark'
  };

  onSave(html: string) {
    console.log('Saved:', html);
  }

  onContentChange(html: string) {
    console.log('Changed:', html);
  }
}

✨ Features

📝 Rich Text Editing

| Feature | Details | |---------|---------| | Text Formatting | Bold, Italic, Underline, Strikethrough, Superscript, Subscript | | Fonts | 12 font families with live preview | | Font Sizes | 18 sizes from 8px to 72px | | Colors | 60+ text colors and 32+ highlight colors | | Alignment | Left, Center, Right, Justify | | Lists | Bullet, Numbered, Indent/Outdent | | Undo/Redo | Full history support |

🎨 Advanced Formatting

| Feature | Details | |---------|---------| | Line Spacing | 6 presets: 1.0, 1.15, 1.5, 2.0, 2.5, 3.0 | | Letter Spacing | 5 options from Tight to Widest | | Text Transform | UPPERCASE, lowercase, Capitalize | | Text Shadows | 5 shadow effects with live preview | | Block Formats | H1–H6, Blockquote, Code Block |

🖼️ Media & Content

  • Images — Upload, resize with drag handles, position control
  • Links — Insert/edit with new tab option
  • Tables — Create, edit, add/delete rows & columns, styling
  • File Attachments — Upload and attach files with icons
  • Horizontal Rules — Insert dividers

🔤 Special Characters (200+)

  • Symbols — ©, ®, ™, §, arrows, checkmarks, stars
  • Emojis — 😊 😍 👍 ❤️ ⭐ 🔥 and 90+ more
  • Math — α, β, π, Σ, ∫, √, ≈, ≠, ∞
  • Currency — $, €, £, ¥, ₹, ₿

💾 Auto-Save

  • Saves to localStorage automatically
  • Configurable save intervals
  • Draft recovery on page reload
  • Visual save indicator

📱 Responsive Preview

  • Mobile (375px), Tablet (768px), Desktop (1200px)
  • Live content preview in device frames

📤 Export Options

  • Print, Print Preview, Export to PDF

🔍 Find & Replace

  • Case-sensitive search, Regex support
  • Find next/previous, Replace one or all

⌨️ Keyboard Shortcuts

| Shortcut | Action | |----------|--------| | Ctrl+B | Bold | | Ctrl+I | Italic | | Ctrl+U | Underline | | Ctrl+Z | Undo | | Ctrl+Y | Redo | | Ctrl+F | Find & Replace |


⚙️ Configuration

interface EditorConfig {
  // Basic
  placeholder?: string;           // Default: 'Start typing...'
  minHeight?: number;             // Default: 400
  maxHeight?: number;
  initialContent?: string;
  autoFocus?: boolean;            // Default: false
  spellcheck?: boolean;           // Default: true
  theme?: 'dark' | 'light';       // Default: 'dark'

  // Auto-Save
  autoSave?: boolean;             // Default: false
  autoSaveInterval?: number;      // Default: 30000 (ms)
  autoSaveKey?: string;           // Default: 'ngx-pro-editor-autosave'

  // Image Upload
  imageUploadHandler?: (file: File) => Promise<string>;
  maxImageSize?: number;          // Default: 5242880 (5MB)

  // File Upload
  fileUploadHandler?: (file: File) => Promise<string>;
  maxFileSize?: number;           // Default: 10485760 (10MB)
}

With Auto-Save

editorConfig = {
  autoSave: true,
  autoSaveInterval: 30000,
  autoSaveKey: 'my-editor-draft',
  theme: 'dark'
};

With Image Upload

editorConfig = {
  imageUploadHandler: async (file: File) => {
    const formData = new FormData();
    formData.append('image', file);
    const res = await fetch('/api/upload', { method: 'POST', body: formData });
    const data = await res.json();
    return data.url;
  },
  maxImageSize: 5 * 1024 * 1024
};

🎯 Component API

Inputs

| Input | Type | Default | Description | |-------|------|---------|-------------| | config | EditorConfig | DEFAULT_EDITOR_CONFIG | Editor configuration | | initialValue | string | '' | Initial HTML content | | title | string | 'Document' | Document title |

Outputs

| Output | Type | Description | |--------|------|-------------| | save | EventEmitter<string> | Fired when save is clicked | | htmlChange | EventEmitter<string> | Fired on every content change |

Methods

getHTML(): string        // Get current HTML content
setHTML(html: string): void  // Set HTML content programmatically
clearAutoSave(): void    // Clear saved draft

ViewChild Example

import { Component, ViewChild } from '@angular/core';
import { NgxProEditorComponent } from 'ngx-pro-editor';

@Component({
  template: `
    <ngx-pro-editor #editor [config]="config" (save)="onSave($event)">
    </ngx-pro-editor>
    <button (click)="getContent()">Get Content</button>
    <button (click)="clearDraft()">Clear Draft</button>
  `
})
export class MyComponent {
  @ViewChild('editor') editor!: NgxProEditorComponent;

  config = { autoSave: true };

  onSave(html: string) { /* save to backend */ }
  getContent() { console.log(this.editor.getHTML()); }
  clearDraft() { this.editor.clearAutoSave(); }
}

🎨 Theming

config = { theme: 'dark' };   // Dark (default)
config = { theme: 'light' };  // Light

Override CSS variables in your global styles:

:root {
  --color-primary: #4f46e5;
  --color-primary-hover: #4338ca;
  --bg-editor: #1a1a2e;
  --text-primary: #ffffff;
  --border-default: #2d2d3a;
}

🌐 Browser Support

| Browser | Version | |---------|---------| | Chrome | 90+ | | Firefox | 88+ | | Safari | 14+ | | Edge | 90+ |


🤝 Contributing

Contributions are welcome! Please open an issue or submit a Pull Request on GitHub.


📄 License

MIT © Shubham Chauhan


🔗 Links


Built with ❤️ using Angular 17+ | Zero external editor dependencies | Production-ready

⭐ If you find this useful, star it on GitHub!