You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Environment: Node, 11ty static site generator, Rollup bundler, Netlify CDN
Description
Prism is working fine, although I get a type error when pages load. Here is the type error:
In Chrome: Uncaught TypeError: Cannot read property 'defer' of null
In Firefox: TypeError: e is null
Here is the code the type error references:
var e = _.util.currentScript();
if (e && (_.filename = e.src, e.hasAttribute("data-manual") && (_.manual = !0)), !_.manual) {
var n = function n() {
_.manual || _.highlightAll();
};
var t = document.readyState;
"loading" === t || "interactive" === t && e.defer ? document.addEventListener("DOMContentLoaded", n) : window.requestAnimationFrame ? window.requestAnimationFrame(n) : window.setTimeout(n, 16);
}
I am not using prismjs and babel-plugin-prismjs packages, as directed in the Prism docs "Usage with Webpack, Browserify, & Other Bundlers" as I cannot get this setup to work with my bundler, Rollup. Instead, I've pasted the prism.js code into the bottom of my script.js, which Rollup bundles.
On Fri, 1 Nov 2019 at 17:31, Michael Schmidt ***@***.***> wrote:
Closed #2105 <#2105> via #2106
<#2106>.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#2105?email_source=notifications&email_token=AHGNJECKDV7ZINJJ4EZISMTQRSN2VA5CNFSM4JH5QWC2YY3PNVWWK3TUL52HS4DFWZEXG43VMVCXMZLOORHG65DJMZUWGYLUNFXW5KTDN5WW2ZLOORPWSZGOUTDZBUQ#event-2764542162>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AHGNJEEUFPUWGJK4UBOQSALQRSN2VANCNFSM4JH5QWCQ>
.
Information:
Description
Prism is working fine, although I get a type error when pages load. Here is the type error:
Uncaught TypeError: Cannot read property 'defer' of null
TypeError: e is null
Here is the code the type error references:
I am not using prismjs and babel-plugin-prismjs packages, as directed in the Prism docs "Usage with Webpack, Browserify, & Other Bundlers" as I cannot get this setup to work with my bundler, Rollup. Instead, I've pasted the prism.js code into the bottom of my script.js, which Rollup bundles.
Example
This is the website where I have the bug: https://www.thwcorbin.com
And here is the code in my repository: https://github.com/ThwCorbin/toms-site/blob/master/src/assets/js/script.js
The text was updated successfully, but these errors were encountered: