anorgatarrak-wordpress-theme/node_modules/underscore.string/dasherize.js

6 lines
163 B
JavaScript

var trim = require('./trim');
module.exports = function dasherize(str) {
return trim(str).replace(/([A-Z])/g, '-$1').replace(/[-_\s]+/g, '-').toLowerCase();
};