|Written by Kay Ewbank|
|Tuesday, 10 March 2020|
Tenko has been developed by Peter van der Zee, an ex-Facebook developer who worked on Infra JS. He chose the name Tenko for the project because it's an anagram of Token, and in Japanese it's a divine beast - the heavenly fox.
More practically, Tenko supports anything stage 4 up to ES11 / ES2020, as well as deep Regex syntax. It supports a variety of parsing modes, from strict and module to sloppy / non-strict, as well as web compatible/AnnexB.
comes with optional (but enabled by default) support for abstract syntax trees (AST). The default AST that is enabled is Estree, but there's also support for Acorn and any stage 4 Babel except for comments. Van der Zee says Optional chaining AST works but AST spec seems to be still in flux. The AST supports location data, matching Acorn or Babel for reference.
Tenko comes with 33,000 input syntax tests, and passes the March 2020 ES test262 suite. It has a web-based REPL that can display the output in the parsing modes mentioned earlier (strict, module, sloppy, web compatible, and ES versions6 to 11. The REPL can only run in browsers that have with native support for ES module loading.
It's worth noting that while Tenko is open source, the developers haven't decided on an open-source license, so couldn't be recommended for any production projects.
|Last Updated ( Tuesday, 10 March 2020 )|