• 
      

    Convert a few more views to ES6.

    Review Request #10305 — Created Nov. 2, 2018 and submitted

    Information

    Review Board
    release-4.0.x
    ee5c303...

    Reviewers

    This change migrates the remaining files in rb/js/views/ to ES6 syntax
    and features.

    Ran js-tests.

    Description From Last Updated

    This line is too long.

    chipx86chipx86

    Wrong multi-line comment format.

    chipx86chipx86

    Indented one level too far.

    chipx86chipx86

    Array

    chipx86chipx86

    This line's too long.

    chipx86chipx86

    Space after arg name.

    chipx86chipx86

    Can we spread this across lines?

    chipx86chipx86

    For readability, can we move the nameToRow[fieldName] bit out into something like elIndex? Took me a minute to figure out …

    chipx86chipx86

    Missing trailing comma.

    chipx86chipx86

    Missing trailing comma.

    chipx86chipx86

    Trailing comma?

    chipx86chipx86

    Col: 27 'errorListEl' is defined but never used.

    reviewbotreviewbot

    I don't think we do this anywhere else for options. Instead, we list the individual options as optional if they …

    chipx86chipx86

    There's no event parameter in this function.

    chipx86chipx86

    Same here.

    chipx86chipx86
    david
    chipx86
    1. 
        
    2. Show all issues

      This line is too long.

    3. Show all issues

      Wrong multi-line comment format.

    4. Show all issues

      Indented one level too far.

    5. Show all issues

      Array

    6. Show all issues

      This line's too long.

    7. Show all issues

      Space after arg name.

    8. Show all issues

      Can we spread this across lines?

    9. Show all issues

      For readability, can we move the nameToRow[fieldName] bit out into something like elIndex? Took me a minute to figure out what this was doing.

      Also, if we're indexing it this way, we're getting a DOM element, not a jQuery element.

    10. Show all issues

      Missing trailing comma.

    11. Show all issues

      Missing trailing comma.

    12. Show all issues

      Trailing comma?

    13. 
        
    david
    Review request changed
    david
    chipx86
    1. 
        
    2. Show all issues

      I don't think we do this anywhere else for options. Instead, we list the individual options as optional if they are.

      1. We do where there's actually a default value (options={}) and the entire parameter is optional.

    3. 
        
    chipx86
    1. 
        
    2. reviewboard/static/rb/js/views/uploadDiffView.es6.js (Diff revision 4)
       
       
       
       
       
       
       
       
      Show all issues

      There's no event parameter in this function.

    3. reviewboard/static/rb/js/views/uploadDiffView.es6.js (Diff revision 4)
       
       
       
       
       
       
       
      Show all issues

      Same here.

    4. 
        
    david
    Review request changed
    Status:
    Completed
    Change Summary:
    Pushed to release-4.0.x (119f102)