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.

Bug in indentation

See original GitHub issue

I recently added the feature to display the invisible characters (spaces) in my application, but when I create a new line, the indentation is not respected. It’s done x5 or more.

In fact, there is an issue only when I make a new line in a script or style tag. The bug occurs even if showInvisibles is disabled. But not in HTML structure. I let the picture tell you more.

  • I use the latest version of CodeMirror, 5.39.0

Here’s a screenshot of what it looks like: localhost_8080___dev index html_modal setting

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (7 by maintainers)

github_iconTop GitHub Comments

2reactions
jdbruxellescommented, Jul 10, 2018

The issue is solved. I was just getting the tabSize and indentUnit as a string from cookies. It looks like they must be numbers, so I use Number().

1reaction
jdbruxellescommented, Jun 26, 2018

There was a cache issue. Sorry and thanks 😉

Read more comments on GitHub >

github_iconTop Results From Across the Web

Correct indentation allows for better understanding and bug ...
It is recommended to correctly indent the lines as it allows for the code to be readable and understandable by the user as...
Read more >
Indentation Bugs - Google Groups
Hello,. I don't know if this is a known issue, but the Eclipse plugin has some annoying bugs regarding indentation for me. In...
Read more >
Suspected bug in Word 365 "Mirror indents" behavior
If a Hanging indent is included with Inside & Outside indentation, the paragraphs are displayed correctly, with the inside and outside indent ...
Read more >
Bug: Indentation problem | Codecademy
I removed all the indentation and line breaks of the class Animal untill it was just a line. Then pressed enter right after...
Read more >
Python Indentation bug? - Stack Overflow
1 Answer 1 ... You've mixed tabs and spaces. Most of your code is indented with spaces, but a few lines have tabs,...
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