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-html-writer

v3.1.1

Published

Some react components to animate HTML code writing.

Readme

React HTML Writer

Here are some components that will allow you to animate HTML writing on your React application.

Installation

$ npm i react-html-writer

Components

Tag

<Tag></Tag>

As a normal HTML tag, you can nest as much Tag and Text components as you want.

| Propertie | Type | Description | | --------- | ------- | --------------------------------------------------------------------------------- | | name | String | Define the tagname (div, span, ...) | | attr | Object | Add attributes to your tags ( These attributes do not affect child components ) | | open | Boolean | Open de tags when the writing is finished | | loop | Boolean | Loop the animation |

Text

<Text />

This component is only used to write strings. The Text component is complitely independent from the Tag component, which means that you can use it by itself to simulate keyboard simple text writing.

| Propertie | Type | Description | | --------- | ------ | -------------------------- | | text | String | Define the string to write | | style | Object | Style the defined text |

Styling

You can change the color of each part of your Text and Tags.

<Text /> can be styled via the style property from react.

<Tag></Tag> in the other hand are customizable through the theme prop. You can use those to change colors, sizes, and fonts.

| Variable | Description | | --------------------- | ----------------------------------------------------- | | cursorColor | the cursor color | | textColor | text color | | tagHookColor | hooks color, so the greater and minus than ("<", ">") | | tagNameColor | tag names color | | attrNameColor | the attributes name color | | attrSymbolColor | symbols color, the "=" symbol basically | | attrQuoteColor | attributes name color | | attrValueColor | attributes value color | | selectColor | the selection color | | selectBackgroundColor | the background selection color | | fontSize | the font size | | fontFamily | the font | | tagTabsize | tabulation size on indentation |

Usage

For a full demo with animtions, try this CodeSandBox or use the Demo page npm run demo.

A simple usage with a simple HelloWorld.

import React from 'react'
import { Tag, Text } from 'react-html-writer'

const HelloWorld = () => (
	<Tag name="h1">
		<Text text="Hello World!" />
	</Tag>
)

export default HelloWorld

The end result will look like this. ( no animation )

<h1>Hello World !</h1>

If you want to import the library via the script tag in your HTML file, you can by using the HTMLWriter global object.

Todolist

  • [x] Create or choose a theme for each component (color, font, size, ...)
  • [ ] Add a duration setting
  • [ ] Add a timeline
  • [x] Add @types