5.0.0 • Published 4 years ago

eo-typewriterjs v5.0.0

Weekly downloads
4
License
MIT
Repository
github
Last release
4 years ago

Navigation

Description

TypewriterJS is a promise-based virtual typewriter that offers an easy and hackable way of producing and maintaining typewriter-like animations on text, basic stuff like typing, deleting and moving the cursor around are only at the command of a method call.

Installation

npm

npm install eo-typewriterjs

bower

bower install eo-typewriterjs

yarn

yarn add eo-typewriterjs

cdn

https://cdn.jsdelivr.net/npm/eo-typewriterjs@latest/dist/typewriter.js

manual

Download the latest version from here. Download a specific version from here.

The following is only applicable starting from version 4.0.0.

  1. Navigate to the dist folder inside of the downloaded package.
  2. Copy either of typewriter.js or typewriter.min.js to your project.

Building

  1. Clone the GitHub repository https://github.com/EOussama/typewriterjs.git.
  2. Run npm install to install all the dependencies.
  3. Run npm run prod to build the package.
  4. The production script will be placed in the dist folder.

Usage

The following example types the string “Hello, world!”:

index.js

<div id="target"></div>

script.js

var typewriter = new Typewriter("#target");
typewriter.type("Hello, world!");

See more use cases here.

Credits

Icon made by Freepik from www.flaticon.com