Save 25% on our pro plugins with coupon code: SPRING2023
Web Dev + WordPress + Security

WordPress Plugin: Prismatic

[ Prismatic ]

I’ve been using other plugins to display my code at Perishable Press, Plugin Planet, DigWP, and WP-Mix for years now. The other plugins have done the job, but there are things that I’ve always wanted to change. For example, syntax highlighting. I use syntax highlighting for code snippets at WP-Mix, but not on any of my other sites. So I wanted to combine clean, time-tested code escaping with stylish syntax highlighting. After sharing well over 1,000 code snippets online, I figure it’s finally time to make it happen..

Announcing Prismatic — a plugin that cleanly escapes code snippets and applies syntax-highlighting using either Prism.js or Highlight.js.

Choose your library

Display beautiful code snippets with Prism.js, Highlight.js, or plain code escaping:

  • Prism.js – Code escape + syntax highlight using Prism.js
  • Highlight.js – Code escape + syntax highlight using Highlight.js
  • Plain Flavor – Code escape without syntax highlight (for custom styles)

Prism.js Features

Prismatic brings the following features when Prism.js is enabled:

  • Supports over 30 coding languages
  • Choose from all 7 available Prism themes
  • Enable Prism plugin Line Numbers
  • Enable Prism plugin Line Highlight
  • Enable Prism plugin Show Language
  • Highlights code in post content, excerpts, and comments
  • Detects language- and lang- class prefixes
  • Limit syntax highlighting to Posts and Pages
  • Highlight single-line and multi-line code
  • Granular control over code escaping
  • Smart loading of CSS & JS assets

Highlight.js Features

Prismatic brings the following features when Highlight.js is enabled:

  • Supports 23 coding languages
  • Choose from all 77 available Highlight themes
  • Customize the Highlight.js init JavaScript
  • Highlights code in post content, excerpts, and comments
  • Limit syntax highlighting to Posts and Pages
  • Highlight multi-line blocks of code
  • Detects language- and lang- class prefixes
  • Enable support for no-prefix class names
  • Granular control over code escaping
  • Smart loading of CSS & JS assets

Code Escaping

Prismatic brings the following features when using the “Plain Flavor” option (for code escaping without syntax highlighting):

  • Enable code escaping for post content, excerpts, and/or comments
  • Enable code escaping on the frontend, Admin Area, or both
  • Escapes single-line and multi-line code snippets

Prismatic also provides these same code-escape options when using Prism.js or Highlight.js. You get clean, beautiful code with or without syntax highlighting, it’s completely up to you :)

Screenshots

Here is a screenshot of Prismatic in action:

[ Prismatic Syntax Highlighting ]
Prismatic – Choose from over 80 syntax-highlight themes

You can check out more screenshots at the WP Plugin Directory. And check out a live site that is using Prismatic (scroll down to code samples).

Get Prismatic

Prismatic is designed for optimal performance: it only loads required CSS and JavaScript when there are code snippets on the page. Prismatic is flexible: you choose the best library, theme, and features for your site. Likewise with code escaping: you choose when and where to escape your code snippets on the front-end and in the Admin Area. Prismatic is secure: built with the WP API and solid PHP functionality.

Jeff Starr
About the Author
Jeff Starr = Creative thinker. Passionate about free and open Web.
SAC Pro: Unlimited chats.

One response to “WordPress Plugin: Prismatic”

  1. Avatar photo

    Prismatic looks stellar! We have started to use it as a dev tool on a few sites and digging it so far. I can’t say it will replace anything so far, but I do like that it only loads the essentials. It also appears to be coded beautifully and securely.

Comments are closed for this post. Something to add? Let me know.
Welcome
Perishable Press is operated by Jeff Starr, a professional web developer and book author with two decades of experience. Here you will find posts about web development, WordPress, security, and more »
.htaccess made easy: Improve site performance and security.
Thoughts
Excellent (and free) tool to test your site's SSL configuration.
Plugin updates! All of our free and pro plugins ready for WordPress 6.2.
Daylight savings is a complete waste of time and needs to be eliminated.
Got a couple of snow days here in mid-March. Fortunately it's not sticking.
I handle all email in real time as it comes in, perpetually clear inbox for years now.
Added some nice features to Wutsearch search engine launchpad. Now 21 engines!
.wp TLD plz :)
Newsletter
Get news, updates, deals & tips via email.
Email kept private. Easy unsubscribe anytime.