Enable Shortcodes in Widgets Without a Plugin

It’s annoying that WordPress doesn’t automatically allow shortcodes in widgets, luckily it only requires a few lines of code to include this functionality. Paste the below into your functions.php file: