
Product
Introducing Module Reachability: Focus on the Vulnerabilities That Matter
Module Reachability filters out unreachable CVEs so you can focus on vulnerabilities that actually matter to your application.
prism-theme-vars
Advanced tools
A customizable Prism.js theme using CSS variables
npm i prism-theme-vars
import 'prism-theme-vars/base.css'
or
<link
rel="stylesheet"
href="https://cdn.jsdelivr.net/npm/prism-theme-vars/base.css"
/>
Add CSS variables in your CSS, For example:
@import 'prism-theme-vars/base.css';
:root {
--prism-foreground: #393a34;
--prism-background: #fbfbfb;
--prism-comment: #b8c4b8;
--prism-string: #c67b5d;
--prism-literal: #3a9c9b;
--prism-keyword: #248459;
--prism-function: #849145;
--prism-deleted: #a14f55;
--prism-class: #2b91af;
--prism-builtin: #a52727;
--prism-property: #ad502b;
--prism-namespace: #c96880;
--prism-punctuation: #8e8f8b;
--prism-decorator: #bd8f8f;
--prism-json-property: #698c96;
}
See base.css for more options avaliable.
We have a few themes variables built-in that you can directly use.
@import 'prism-theme-vars/base.css';
@import 'prism-theme-vars/themes/vitesse-light.css';
/* Overrides */
:root {
--prism-background: #ffffff;
}
See all themes avaliable under themes/*. Contributions are also greatly welcome!
codemirror-theme-vars
@import 'prism-theme-vars/base.css';
@import 'prism-theme-vars/to-codemirror.css';
/* --prism prefix will alias to --cm automatically */
:root {
--prism-foreground: #393a34;
--prism-background: #fbfbfb;
}
Here is an example of Tailwind CSS favored dark mode support.
html:not(.dark) {
--prism-foreground: #393a34;
--prism-background: #f8f8f8;
--prism-comment: #758575;
--prism-namespace: #444444;
--prism-string: #bc8671;
--prism-punctuation: #80817d;
--prism-literal: #36acaa;
--prism-keyword: #248459;
--prism-function: #849145;
--prism-deleted: #9a050f;
--prism-class: #2b91af;
--prism-builtin: #800000;
--prism-property: #ce9178;
--prism-regex: #ad502b;
}
html.dark {
--prism-foreground: #d4d4d4;
--prism-background: #1e1e1e;
--prism-namespace: #aaaaaa;
--prism-comment: #758575;
--prism-namespace: #444444;
--prism-string: #ce9178;
--prism-punctuation: #d4d4d4;
--prism-literal: #36acaa;
--prism-keyword: #38a776;
--prism-function: #dcdcaa;
--prism-deleted: #9a050f;
--prism-class: #4ec9b0;
--prism-builtin: #d16969;
--prism-property: #ce9178;
--prism-regex: #ad502b;
}
MIT
FAQs
A customizable Prism.js theme using CSS variables
The npm package prism-theme-vars receives a total of 7,251 weekly downloads. As such, prism-theme-vars popularity was classified as popular.
We found that prism-theme-vars demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Module Reachability filters out unreachable CVEs so you can focus on vulnerabilities that actually matter to your application.
Product
Socket is introducing a new way to organize repositories and apply repository-specific security policies.
Research
Security News
Socket researchers uncovered malicious npm and PyPI packages that steal crypto wallet credentials using Google Analytics and Telegram for exfiltration.