question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Re-indent comments

See original GitHub issue

As requested in #639, I’m opening up a separate ticket for [comments incorrectly being indented]

function theFunction2(action$, store) {
    /*
     * comments
     */
	return true;
    /*
     * comments
     */
}

turns into

function theFunction2(action$, store) {
  /*
     * comments
     */
  return true;
  /*
     * comments
     */
}

https://jlongster.github.io/prettier/#{"content"%3A"function theFunction2(action%24%2C store) {\n %2F*\n * comments\n *%2F\n\treturn true%3B\n %2F*\n * comments\n *%2F\n}\n\n"%2C"options"%3A{"printWidth"%3A80%2C"tabWidth"%3A2%2C"singleQuote"%3Afalse%2C"trailingComma"%3Afalse%2C"bracketSpacing"%3Atrue%2C"doc"%3Afalse}}

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:21
  • Comments:18 (12 by maintainers)

github_iconTop GitHub Comments

1reaction
maxdeviantcommented, Sep 15, 2017

@bcherny I have a PR that is close to completion. I’ll see if I can get it finished up this weekend.

0reactions
bchernycommented, Sep 15, 2017

Thanks for the hard work everyone. Are there any updates? This is blocking https://github.com/bcherny/json-schema-to-typescript/issues/45

Read more comments on GitHub >

github_iconTop Results From Across the Web

Reindent command breaks on (multiline) comments #1271
Selecting an entire document that contains comments that span multiple lines, and using the Edit -> Line -> Reindent command, stops indenting at...
Read more >
reindent-one-line-c-comments: preference buffer-specific variable
This variable controls how Epsilon indents comment lines that start with "//". If 0 , Epsilon never changes the indentation of these lines...
Read more >
Reindent is broken by trailing comments in C++ - Sublime Forum
Trailing comments break reindenting in C++. The line is not moved and everything after it is then broken. Here is an example:
Read more >
formatting - Vim: Automated way to reformat and reindent comments ...
5. delete empty comments ... Press qq to start recording; Press gg to go to the beginning of the file; Press gq} to...
Read more >
Reformat and rearrange code | PyCharm Documentation
PyCharm lets you reformat your code according to the requirements you've ... the Turn formatter on/off with markers in code comments option.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found