Has Code tag

Post #407 written by Khodok in Tags Updates

Content

Optimization!

What’s new

  • Just added a new snippet of code that returns whether a post has the tag called has_code.
    • If it does, the post loads the necessary CSS, else, of course, it doesn’t.

I added this because the CSS for Code highlighting is heavy, and even if it wasn’t, it shouldn’t be loaded when not required.
It also allows one to find all posts containing code.

Comments

Please Log in to leave a comment.

No comments yet.