Skip to content

Commit 9633564

Browse files
Plugins: Consistent Prism check (#2788)
1 parent cb22016 commit 9633564

File tree

51 files changed

+144
-147
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+144
-147
lines changed

plugins/autolinker/prism-autolinker.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
(function(){
22

3-
if (
4-
typeof self !== 'undefined' && !self.Prism ||
5-
typeof global !== 'undefined' && !global.Prism
6-
) {
3+
if (typeof Prism === 'undefined') {
74
return;
85
}
96

plugins/autolinker/prism-autolinker.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

plugins/autoloader/prism-autoloader.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
(function () {
2-
if (typeof self === 'undefined' || !self.Prism || !self.document || !document.createElement) {
2+
3+
if (typeof Prism === 'undefined' || typeof document === 'undefined') {
34
return;
45
}
56

plugins/autoloader/prism-autoloader.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

plugins/command-line/prism-command-line.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
(function () {
22

3-
if (typeof self === 'undefined' || !self.Prism || !self.document) {
3+
if (typeof Prism === 'undefined' || typeof document === 'undefined') {
44
return;
55
}
66

plugins/command-line/prism-command-line.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

plugins/copy-to-clipboard/prism-copy-to-clipboard.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
(function () {
2-
if (typeof self === 'undefined' || !self.Prism || !self.document) {
2+
3+
if (typeof Prism === 'undefined' || typeof document === 'undefined') {
34
return;
45
}
56

0 commit comments

Comments
 (0)