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

react-quill-editors

v1.0.5

Published

A fully customizable React rich text editor with no external dependencies. Features a comprehensive toolbar similar to popular Markdown editors with file operations, media insertion, and advanced formatting capabilities.

Downloads

19

Readme

React Quill Editors

A fully customizable React rich text editor with no external dependencies. Built from scratch using only React and native browser APIs. Features a comprehensive toolbar similar to popular Markdown editors with file operations, media insertion, and advanced formatting capabilities.

✨ Features

  • No external dependencies - Built entirely with React and native browser APIs
  • Markdown editor-style interface - Comprehensive toolbar with file operations, formatting, and media tools
  • Fully customizable - Enable/disable features via props
  • Modern UI - Clean, responsive design with professional styling
  • TypeScript support - Full TypeScript definitions included
  • Accessible - Keyboard navigation and screen reader support
  • Lightweight - Minimal bundle size
  • File operations - Save, delete, close functionality
  • Media support - Insert links, images, videos, and attachments
  • Advanced formatting - Headings, code blocks, quotes, horizontal rules
  • Color controls - Text and background color options
  • Font controls - Size and family selection
  • Alignment tools - Left, center, right, justify alignment
  • List support - Bullet and numbered lists
  • Preview mode - Real-time content preview

🚀 Installation

npm install react-quill-editors

📖 Quick Start

import { RichTextEditor } from 'react-quill-editors';

function App() {
  const [content, setContent] = useState('');

  return (
    <RichTextEditor
      features={{
        // File operations
        save: true,
        delete: true,
        close: true,
        
        // Text formatting
        heading: true,
        bold: true,
        italic: true,
        underline: true,
        strikethrough: true,
        
        // Font controls
        fontSize: true,
        fontFamily: true,
        
        // Colors
        color: true,
        bgColor: true,
        
        // Alignment
        align: true,
        
        // Lists
        lists: true,
        
        // Media
        link: true,
        image: true,
        video: true,
        
        // Special formatting
        code: true,
        quote: true,
        horizontalRule: true,
        
        // Additional features
        attachment: true,
        preview: true,
      }}
      value={content}
      onChange={setContent}
      onSave={() => console.log('Saving...')}
      onDelete={() => console.log('Deleting...')}
      onClose={() => console.log('Closing...')}
      onPreview={() => console.log('Preview...')}
      placeholder="Start typing..."
    />
  );
}

📚 API Reference

RichTextEditor Props

| Prop | Type | Default | Description | |------|------|---------|-------------| | features | EditorFeatures | {} | Object to enable/disable specific features | | value | string | '' | The HTML content of the editor | | onChange | (value: string) => void | - | Callback when content changes | | placeholder | string | 'Start typing...' | Placeholder text when editor is empty | | className | string | '' | Additional CSS class name | | style | React.CSSProperties | {} | Inline styles for the editor | | readOnly | boolean | false | Makes the editor read-only | | disabled | boolean | false | Disables the editor completely | | onSave | () => void | - | Callback for save button | | onDelete | () => void | - | Callback for delete button | | onClose | () => void | - | Callback for close button | | onPreview | () => void | - | Callback for preview button |

EditorFeatures

| Category | Feature | Prop | Description | |----------|---------|------|-------------| | File Operations | | | | | | Save | save: true | Save button with callback | | | Delete | delete: true | Delete button with callback | | | Close | close: true | Close button with callback | | Text Formatting | | | | | | Heading | heading: true | Insert headings (H1-H6) | | | Bold | bold: true | Toggle bold text | | | Italic | italic: true | Toggle italic text | | | Underline | underline: true | Toggle underlined text | | | Strikethrough | strikethrough: true | Toggle strikethrough text | | Font Controls | | | | | | Font Size | fontSize: true | Change text size (8px-36px) | | | Font Family | fontFamily: true | Change font family | | Colors | | | | | | Text Color | color: true | Change text color | | | Background Color | bgColor: true | Change background color | | Alignment | | | | | | Alignment | align: true | Text alignment (left, center, right, justify) | | Lists | | | | | | Lists | lists: true | Bullet and numbered lists | | Media | | | | | | Link | link: true | Insert links | | | Image | image: true | Insert images | | | Video | video: true | Insert videos | | Special Formatting | | | | | | Code | code: true | Insert code blocks | | | Quote | quote: true | Insert blockquotes | | | Horizontal Rule | horizontalRule: true | Insert horizontal rules | | Additional Features | | | | | | Attachment | attachment: true | File attachment functionality | | | Preview | preview: true | Preview mode with callback |

💡 Usage Examples

Basic Editor

import { RichTextEditor } from 'react-quill-editors';

function BasicEditor() {
  const [content, setContent] = useState('');

  return (
    <RichTextEditor
      features={{
        bold: true,
        italic: true,
        underline: true,
      }}
      value={content}
      onChange={setContent}
    />
  );
}

Markdown-Style Editor

import { RichTextEditor } from 'react-quill-editors';

function MarkdownStyleEditor() {
  const [content, setContent] = useState('');

  const handleSave = () => {
    console.log('Saving content:', content);
  };

  const handleDelete = () => {
    if (confirm('Are you sure?')) {
      setContent('');
    }
  };

  return (
    <RichTextEditor
      features={{
        // File operations
        save: true,
        delete: true,
        close: true,
        
        // Text formatting
        heading: true,
        bold: true,
        italic: true,
        underline: true,
        strikethrough: true,
        
        // Font controls
        fontSize: true,
        fontFamily: true,
        
        // Colors
        color: true,
        bgColor: true,
        
        // Alignment
        align: true,
        
        // Lists
        lists: true,
        
        // Media
        link: true,
        image: true,
        video: true,
        
        // Special formatting
        code: true,
        quote: true,
        horizontalRule: true,
        
        // Additional features
        attachment: true,
        preview: true,
      }}
      value={content}
      onChange={setContent}
      onSave={handleSave}
      onDelete={handleDelete}
      placeholder="Start typing your content..."
    />
  );
}

Read-Only Editor

import { RichTextEditor } from 'react-quill-editors';

function ReadOnlyEditor() {
  const content = '<p><strong>This is read-only content</strong> with <em>various formatting</em>.</p>';

  return (
    <RichTextEditor
      features={{
        bold: true,
        italic: true,
        underline: true,
        fontSize: true,
        fontFamily: true,
        color: true,
        align: true,
      }}
      value={content}
      readOnly={true}
    />
  );
}

Custom Styled Editor

import { RichTextEditor } from 'react-quill-editors';

function CustomStyledEditor() {
  const [content, setContent] = useState('');

  return (
    <RichTextEditor
      features={{
        bold: true,
        italic: true,
        color: true,
        align: true,
        lists: true,
      }}
      value={content}
      onChange={setContent}
      className="custom-editor"
      style={{
        border: '2px solid #007bff',
        borderRadius: '8px',
        minHeight: '400px',
        boxShadow: '0 4px 6px rgba(0, 0, 0, 0.1)',
      }}
    />
  );
}

🎨 Available Options

Font Sizes

  • 8px, 10px, 12px, 14px, 18px, 24px, 36px

Font Families

  • Arial, Times New Roman, Courier New, Georgia, Verdana, Helvetica

Color Palette

The editor includes a comprehensive color palette with 15 predefined colors:

  • Basic: Black, White
  • Primary: Red, Green, Blue
  • Secondary: Yellow, Magenta, Cyan
  • Extended: Gray, Maroon, Olive, Purple, Teal, Navy

🌐 Browser Support

  • Chrome 60+
  • Firefox 55+
  • Safari 12+
  • Edge 79+

🛠️ Development

# Install dependencies
npm install

# Start development server
npm run dev

# Build for production
npm run build

# Clean build directory
npm run clean

🤝 Contributing

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.

👨‍💻 Author

Akshay Bhalala

🙏 Acknowledgments

  • Built with React and TypeScript
  • Uses native browser document.execCommand() API
  • Inspired by modern Markdown editors and rich text editors
  • Special thanks to the React community for inspiration and best practices

📦 Keywords

  • react
  • text-editor
  • rich-text
  • wysiwyg
  • editor
  • typescript
  • markdown
  • content-editor
  • html-editor
  • formatting
  • toolbar
  • no-dependencies
  • lightweight
  • customizable
  • accessible
  • modern-ui
  • file-operations
  • media-insertion
  • color-picker
  • font-controls
  • alignment-tools
  • list-support
  • preview-mode