Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/wcoder/typesetter.js

Simple and extensible typesetter with JavaScript
https://github.com/wcoder/typesetter.js

javascript pure-javascript typesetter typesetting typing typing-skills typing-trainer typing-tutor typingspeedtest

Last synced: 17 days ago
JSON representation

Simple and extensible typesetter with JavaScript

Awesome Lists containing this project

README

        

# typesetter.js
Simple and extensible typesetter.

[Demo](https://wcoder.github.io/typesetter.js/index.html)

## Install

```
npm i typesetter.js
```

## Features

- Realistic Key Processing Engine
- Self-contained: Requires zero dependencies to work
- Detecting typos

### Options:

Name | Type | Description
-----|------|-------------
data | string | text content for display
maxErrorsCount | int | limit errors (disable: 0)
cursorAutoShift | bool | skip whitespaces
skipComments | bool | skip comments for `cursorAutoShift`
skipEmptyLines | bool | skip empty lines for `cursorAutoShift`

#### Example
```js
typesetter(element, {
data: "function hashKey(obj) { return 1; }",
maxErrorsCount: 5,
cursorAutoShift: true, // ignore whitespace
skipComments: true, // additional setup for cursorAutoShift
});
```

Developed just for fun. Inspired by the idea of https://typing.io/

---
© 2015 Yauheni Pakala | Apache License 2.0