add support for a listener to capture parse events#249
Conversation
|
I don't have principal objection, if you find such hooks useful. That should not decrease speed, but could you run benchmark for sure? If speed become lower, try to replace /cc @dervus what do you think? PS. If you executed tests manually, make sure you run linter too (see travis report) |
1b9332f to
ecb5c4d
Compare
ecb5c4d to
3f9f8d4
Compare
|
Thanks @puzrin . Delinted. Benchmarks looked very much the same. Seemed slightly better with |
|
LGTM. @dervus any comments about option name and so on? |
|
This change seem to imply public exposure of State object, which I don't like because it would make as to maintain backward comparability for that. I don't object if it'll be non-documented and non-supported feature. |
add support for a listener to capture parse events
|
Ok. Let's merge as hidden treasure :) |
|
Released with this PR. Enjoy! |
from commit 50c82bccf70a19fd4add99542dfdf06a60280da8 (today) with parse listener enhancement nodeca/js-yaml#249
This lets a caller build up a parse tree should they need, without impacting anything else.
Inspired by #248 .