I've seen a couple of Python Javascript tokenizers and a cryptic document on Mozilla.org about a Javascript Lexer but can't find any Javascript tokenizers for PHP specifically. Are there any?
Thanks
I have no experience with either, so I can't tell you anything about what they do and in what detail they tokenize code into, but I can see two:
JSLint is an executable but comes with a PHP interface - probably not enough for you, as it probably doesn't publish the raw tokenization to the calling program
PHPSniffer claims to come with a full Javascript tokenizer that you can maybe tap into. This looks the most interesting.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With