Skip to content
forked from ariya/tapdigit

Simple JavaScript-based math evaluator

License

Notifications You must be signed in to change notification settings

m-thomson/tapdigit

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TapDigit

TapDigit is a simple JavaScript implementation of a math expression lexer, parser, and evaluator.

TapDigit.Lexer splits a math expression into a sequence of tokens. This is useful for e.g. an expression editor with color syntax highlighting.

TapDigit.Parser parses an expression and produces the JSON-formatted syntax tree representation thereof.

TapDigit.Evaluator computes the result of an expression. Variables, constants, and functions supported in the expression syntax can be extended via TapDigit.Context object.

There is also a simple web page (open demo/index.html) which demonstrates how it works.

About this fork

  • TapDigit was originally created by @AriyaHidayat.
  • This fork of TapDigit has been migrated to TypeScript/ES6.
  • Available under the BSD 3 Clause License.

About

Simple JavaScript-based math evaluator

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 86.3%
  • HTML 13.7%