unhyphenate.js 285 Bytes Raw Blame History Permalink 1 2 3 4 5 6 7 8 9 10 var toString = require('../lang/toString'); /** * Replaces hyphens with spaces. (only hyphens between word chars) */ function unhyphenate(str){ str = toString(str); return str.replace(/(\w)(-)(\w)/g, '$1 $3'); } module.exports = unhyphenate;