fix(tsx): Collect multibytes characters in skipped script and styles #1033
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Changes
When I added the ability to skip script and styles, I forgot to take into account that we should still collect the multibytes characters inside of them as we use it to adjust the positions of tags
Additionally, this PR fixes the order in which the end positions are collected, previously we'd collect it before it got adjusted after printing, which lead to the end positions being wrong most of the time. This didn't end up being a problem in the editor tooling, as we don't care too much about end positions (we map from the start position)
Testing
Added a test and updated the tests for the end positions fixes
Docs
N/A