string-remove-widows 3.0.1

  • DoDon’t add non-breaking spaces in front of hyphens/dashes (opts.hyphens === truefalse)
  • HTML-encodeHTML-decode all what was in the scope (opts.convertEntities === truefalse)
  • DoDon’t remove non-breaking spaces used for widow-word prevention (opts.removeWidowPreventionMeasures === truefalse)

Put a string

Program returns a string

and Ranges ???

TIP: check out Butterick’s Practical Typography opens in a new tab
TIP #2: the opens in a new tab, a comprehensive text-preparation tool, uses this program

PS. See the source of this page on GitHub opens in a new tab. Vue.js is driving the UI; both Vue and this program are coming as <script>s from jsDelivr.