Add transformTagName option to transform tag names when parsing#469
Conversation
|
Thanks for this PR @erkie . I'm just wondering that there can be multiple options to format the tag or attribute name. And probably everyone need some combination as per their need. So it could be better to create a function that can be overridden by the user to apply particular formatting. In this way, some more requirements can be covered eg replacing hyphen with camel casing etc. |
344eade to
9ee8d4b
Compare
|
Thanks for the feedback @amitguptagwl I totally agree with you. I amended the PR to be |
|
It looks like some tests are failing. Can you please check? |
9ee8d4b to
5e38a80
Compare
|
@amitguptagwl thanks for that, it was an error with my tests. It has been fixed now. Also, I changed the option name from |
Purpose / Goal
Add an option to transform tag names in output of
.parse. Option name is:Pasting the test here because it's a great sample of what this PR does: