diff --git a/lib/line_wrapper.coffee b/lib/line_wrapper.coffee index 3b18f0a..107edd2 100644 --- a/lib/line_wrapper.coffee +++ b/lib/line_wrapper.coffee @@ -1,5 +1,5 @@ # This regular expression is used for splitting a string into wrappable words -WORD_RE = /([^ ,\/!.?:;\-\n]+[ ,\/!.?:;\-]*)|\n/g +WORD_RE = /([^ ,\/!.?:;\-\n]*[ ,\/!.?:;\-]*)|\n/g {EventEmitter} = require 'events' class LineWrapper extends EventEmitter diff --git a/lib/mixins/text.coffee b/lib/mixins/text.coffee index 66170b1..d415ffa 100644 --- a/lib/mixins/text.coffee +++ b/lib/mixins/text.coffee @@ -1,4 +1,4 @@ -WORD_RE = /([^ ,\/!.?:;\-\n]+[ ,\/!.?:;\-]*)|\n/g +WORD_RE = /([^ ,\/!.?:;\-\n]*[ ,\/!.?:;\-]*)|\n/g LineWrapper = require '../line_wrapper' module.exports =