locked
Code Block adds extra blank line if Question\Discussion is edited RRS feed

  • Question

  • A user creates a Question\Discussion and inserts a code block with multiple lines, then user submits.

    If user edits the same Question\Discussion, the code block will add an extra line after each line of code.

    To illustrate this example, at first submit the code block look like this (2 lines of code with 0 extra blank lines = 2 lines):

    function foo() { /* at Line 1 */ }
    function bar() { /* at Line 2 */ }
    

    Open the same Question\Discussion for edit, the same code block looks like this. This is a real pain, because I have to remove all extra lines before saving (2 lines of code with 2 extra blank lines = 4 lines):

    function foo() { /* at Line 1 */ }
    
    function bar() { /* now at Line 3 */ }
    
    

    If I did not remove extra lines upon saving, then open for edit again another extra line is added (2 lines of code with 4 extra blank lines = 6 lines):

    function foo() { /* at Line 1 */ }
    
    
    function bar() { /* now at Line 4 */ }
    
    
    

    Thanks
    Jeff in Seattle

     

    Friday, May 7, 2010 3:59 PM

Answers