Wordsmith


Wordsmith is a blazing fast, multi-byte safe, one-stop text manipulation toolkit for Craft CMS.

Wordsmith brings dozens of powerful features into your Twig templates:

  • Trim and truncate text or HTML (by paragraph, word, or character)
  • Beautify your typography (smart quotes, widow-prevention, ampersand styling, etc.)
  • Change case and inflection
  • Transliterate international text
  • Search, count, isolate, and replace substrings
  • Parse Emoji, using standard and short names
  • Parse Markdown, in several flavors (including Parsedown)
  • Parse names to get their parts (e.g. first name, last name, etc.)
  • Parse a URL to get its parts (e.g. host name, path, query string, fragment, etc.)
  • Get YouTube video ID from a URL
  • Match and re-case Roman numerals
  • Calculate text statistics like word count, sentence count, and readability
  • Tell whether a variable value is string-like
  • ...and much more...

Wordsmith will work as a backwards-compatible drop-in replacement for several Craft 2 plugins, including: Typogrify, Entitle, Hacksaw, ReadTime, Inflect, and Parsedown

Finally, Wordsmith provides a clean, well-documented, Stringy-compatible service API, so you can easily use all of Wordsmith's methods and libraries in your own plugins and packages.


Free

Package Name

To install this plugin, search for its package name on the Plugin Store and click “Install”.


Information

Report an issue