Add %v and %q options to format in CodeBuilder.buildLine and some handy indentation methods#246
Add %v and %q options to format in CodeBuilder.buildLine and some handy indentation methods#246uWynell wants to merge 3 commits intoKong:masterfrom
Conversation
…dy indentation methods
|
|
|
Sorry, I didn't notice that I accidentally changed package-lock when I didn't have to |
|
hey @uWynell! sorry that I didn't see this sooner, but in #248 we did a bit of a total overhaul and vastly simplified this stuff (in a slightly different way). I'm going to close this PR for now in part also because we removed the Really appreciate your PR, truly, and hope to see more in the future! If I mixed something up please let me know! |
%vand%qoptions to format inCodeBuilder.buildLine. Why? When I implemented Rust's Reqwest target (I'll make the corresponding Pull Request after this one), I noticed the problem of escaping characters. For example, my chrome browser generatessec-ch-uaheader, that contains quotes, and some of the targets do not escape them, which results in broken code. And also I'm using it in the mentioned Reqwest target.indent,unindentandreindentmethods toCodeBuilder, as it allows to control indentation more conveniently.How do
%vand%qoptions work?Right from the comments I made to the new
formatfunction:Examples: