dasherize (str) String
public
Replaces underscores, spaces, or camelCase with dashes.
'innerHTML'.dasherize(); // 'inner-html' 'action_name'.dasherize(); // 'action-name' 'css-class-name'.dasherize(); // 'css-class-name' 'my favorite items'.dasherize(); // 'my-favorite-items' 'privateDocs/ownerInvoice'.dasherize(); // 'private-docs/owner-invoice'
Parameters:
-
str
String
- The string to dasherize.
Returns:
-
String
- the dasherized string.
Please login to continue.