API Reference

util.format Class

Description

String format utilities.

Methods

stripHtml

(content) String static

Removes all HTML tags.

Parameters

Returns

titlecase

(str) String static

See util.inflector/titleize.

Parameters

Returns

trim

(content) String static

Removes whitespace from both ends of the string.

Parameters

Returns

truncate

(text, [options]) String static

Truncates the given text.

Parameters

Returns

word_wrap

(text, width) String static

Wraps the text into lines no longer than width.

Parameters

Returns