[wp-trac] [WordPress Trac] #30966: Let's make word count better (master ticket)

WordPress Trac noreply at wordpress.org
Fri Jun 19 10:35:03 UTC 2015


#30966: Let's make word count better (master ticket)
--------------------------+-------------------------
 Reporter:  iseulde       |       Owner:  iseulde
     Type:  defect (bug)  |      Status:  accepted
 Priority:  normal        |   Milestone:  4.3
Component:  Editor        |     Version:
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |     Focuses:  javascript
--------------------------+-------------------------

Comment (by iseulde):

 In [changeset:"32856"]:
 {{{
 #!CommitTicketReference repository="" revision="32856"
 Editor: restructure word count

 * The WordCounter should only do one thing: count words. This makes it
 also easier to test.
 * Add some really basic unit tests.
 * Instead of only refreshing the count on enter and delete, refresh the
 count when the user stops typing. Also look at paste and content changes
 in TinyMCE.
 * Use `match` instead of `replace` when it is appropriate.
 * More readable code.

 See #30966. Fixes #26620.
 }}}

--
Ticket URL: <https://core.trac.wordpress.org/ticket/30966#comment:29>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list