Last active
December 25, 2015 21:29
-
-
Save SelrahcD/7042692 to your computer and use it in GitHub Desktop.
AngularJs directive for PrismJs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
angular.module('Prism', []). | |
directive('prism', [function() { | |
return { | |
restrict: 'A', | |
link: function ($scope, element, attrs) { | |
element.ready(function() { | |
Prism.highlightElement(element[0]); | |
}); | |
} | |
} | |
}] | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Can you update to this Version:
https://gist.github.com/sunsus/2a5ce3fbe15f447e7fa7
It is better compatible with Plugins.