Git Product home page Git Product logo

typer.js's Introduction

Typer.js

Typing effect completely configurable in HTML

Live page: http://steven.codes/typerjs

example gif of typing effect

<h1>
  I love
  <span class="typer" id="first-typer" data-words="beets,bears,battlestar galactica" data-colors="#cd2032,#cc1e81,#6e6abb"></span>
  <span class="cursor" data-owner="first-typer"></span>
</h1>
<script async src="https://unpkg.com/[email protected]/typer.js"></script>

Never touch the JavaScript if you don't want to.

Features

You're in control of:

  • Keystroke delay and variance
  • Time between deletion of words
  • Cursor display
  • Color of each word
  • Pausing and playing the effect

Read more in the docs

Common bugs

Make sure to load the script after the final usage of Typer.js in your HTML. Due to how browsers parse HTML, a script is guaranteed access to all of the DOM elements that precede the script tag that loaded it. There's no harm in adding the async attribute to your script tag, so that the browser resumes parsing your HTML file while it fetches Typer.js!

typer.js's People

Contributors

droidenator avatar philetaylor avatar rizdaprasetya avatar straversi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

typer.js's Issues

How to write variable.

Hello!
It's not a real issue, but more like a "please help me" situation.

I'm trying to code some sort of terminal where the user is prompted for the name, but I don't know how to print the variable.

<h2>
        <!--Code for the text-->
        <span class="typer" id="recovery_mode"
        data-words="Booting into recovery mode...,Computer: Who... who are you?,Computer: Hello..."+name+"..."
        data-delay="100"
        data-colors="red, gray, gray"
        data-loop="1"></span>

        <!--Code for the cursor-->
        <span class="cursor"
        data-owner="main"></span>
    </h2>
   name = prompt("Who are you?")

I know, this repository hasn't been getting issues for quite some time, but I'll give it a shot.

OS License Type

Hi,

Would it be possible to clarify under what license is this code released? My best guess would be MIT but i couldn't find any reference anywhere (i apologize if i missed anything but i also looked at the website but couldn't find). It would be extremely helpful if you can clarify or add the license file in the root folder

Thanks Much,
Gagan

NPM package

this is really nice and exactly what I want. It would be amazing if this existed as an npm package

General improvements

I created this script a while ago more toward the beginnings of my javascript journey. I'm revisiting it lately to make some updates.

Some things I want to do:

  • refactor to modern javascript, and add a build step to transform it to ES5 for browser support for those who want it
  • add a minification build step
  • write some tests
  • ?

data-deleteDelay

If I understand correct then this setting would allow a word to be fully typed for x-amount of time before its deleted and a new work is made aint that correct? I´ve tried to insert a value here: www.getskillup.com. But no matter how high a value nothing changes.

Unexpected token: punc (.) (line: 35, col: 24, pos: 1061)

Hi! Thanks for this awesome library. I get this error anytime I try to minify the library. Unexpected token: punc (.) (line: 35, col: 24, pos: 1061)

I've tried a few different minification tools with the same results. I'm looking at the code now to see if I can find a resolution.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.