Skip to content

callback function #6

@mattcasey

Description

@mattcasey

would be nice to have some way to call a function after typing is done. I edited 3 places, now I can set $.typer.options.OnDoneTyping before the typing begins
Line 14:

  var
    options = {
      highlightSpeed    : 20,
      typeSpeed         : 100,
      clearDelay        : 500,
      typeDelay         : 200,
      clearOnHighlight  : true,
      typerDataAttr     : 'data-typer-targets',
      typerInterval     : 2000,
      OnDoneTyping      : null
    },

Line 77:

    if (!text || text.length === 0) {
      clearData($e);
      onDoneTyping();
      return;
    }

Line 258:

  onDoneTyping = function () {
    if(typeof $.typer.options.OnDoneTyping == 'function') {
      $.typer.options.OnDoneTyping();
    }
  };

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions