[wp-trac] [WordPress Trac] #26018: Coding standards / whitespace for wp-admin/js/word-count.js

WordPress Trac noreply at wordpress.org
Mon Nov 18 18:42:26 UTC 2013


#26018: Coding standards / whitespace for wp-admin/js/word-count.js
--------------------------+------------------------------
 Reporter:  dougwollison  |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  Build Tools   |     Version:
 Severity:  normal        |  Resolution:
 Keywords:                |
--------------------------+------------------------------

Comment (by dougwollison):

 Replying to [comment:1 jorbin]:
 > Thanks for the patch.  A couple of concerns.
 >
 > If we want to change one of the regexs, we should ideally do it through
 it's own tickets and create unit tests as a part of that.  That specific
 regex has been there for 3 years (since [17936] )
 >
 > All the formatting changes make the svn history much harder to follow
 for this file.  While that is a concern that these jshint changes
 themselves are going to do that as well, the benefits of having a passing
 jshint for preventing bugs and enforcing many parts of our standard out
 ways this cost.  To quote @nacin as we do in our style guide,
 [http://make.wordpress.org/core/handbook/coding-standards/javascript
 /#code-refactoring “Code refactoring should not be done just because we
 can.”].  I think it's fine on lines we are changing anyways and in general
 that is the best way for us to go about cleaning up our files.
 >
 > I've submitted an updated patch with just the jshint related changes

 You're right; if the regex works then ignore that change and use yours. I
 only noticed it anyway because it was screwing with my editor's syntax
 highlighting for the inline comment on that line.

--
Ticket URL: <http://core.trac.wordpress.org/ticket/26018#comment:3>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list