spekulatius
spekulatius

Reputation: 1499

How to proper integrate PrismJS into a Eleventy project?

I'm building a site using eleventy and want to include code examples with code-highlighting. Prism looks like a great choice for this. How would I add it proper to the build process (not as CDN)?

Upvotes: 1

Views: 300

Answers (1)

Raymond Camden
Raymond Camden

Reputation: 10857

Use the download option. This gives you the JS/CSS you need. Copy it to your site and ensure you are using the "Passthrough File Copy" (https://www.11ty.dev/docs/copy/) option to copy CSS and JS files over.

Upvotes: 2

Related Questions