Closed vemoo closed 5 years ago
I've realized theres options.unescape but it doesn't seem to do anything in this case.
That's not right, this is a bug, and it's inconsistent with how picomatch works. It should allow you to retain escaping. Thank you for reporting it.
ah, wait. The option is keepEscaping
. I forgot that I used a different option name to allow you to escape one or the other, or both. If both picomatch and braces had the same option name (unescape
) for this specifically, you wouldn't be able to control escaping.
Try this:
console.log(braces("C:/Program Files \\(x86\\)", { keepEscaping: true }));
Yes, that works. Then the documentation should be updated and it should be added to the documentation of micromatch.
Then the documentation should be updated and it should be added to the documentation of micromatch.
Agreed! Thanks for reporting this. Want to do a PR?
I'm not sure if it's a braces or micromatch issue, but
returns
losing the escape characters, making
return the tokens
vs what I expected and what
returns
Here's some sample code: https://repl.it/repls/SharpStrangeChemistry