Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
@bobril/highlighter
Advanced tools
Bobril component for syntax highlighting of source code. For actual work uses highlight.js.
Updated to use version 11.9.0 of highlight.js.
import * as b from "bobril";
import * as high from "@bobril/highlighter";
import { docco } from "@bobril/highlighter/styles";
b.init(() => <high.Highlighter style={docco}>{`let actual = "code " + "shine";`}</high.Highlighter>);
By default only most common languages are registered. If all are needed use this:
import "@bobril/highlighter/allLanguages";
language?: string
- if not provided then autodetect (slower)style?: HighlightStyle
- provide theme to use for stylingshowLineNumbers?: boolean
- default is true
startingLineNumber?: number
- default is 1
, NaN
is automatically set to 1
as well.lineStyle?: ((line: number) => b.IBobrilStyles) | undefined
- allow style div
for each linelineContentStyle?: ((line: number) => b.IBobrilStyles) | undefined
- allow to style div
of line content without line numberlineNumberStyle?: ((largestLineNumber: number, style: HighlightStyle) => (line: number) => b.IBobrilStyles) | undefined
- allows complete override of default line number stylechildren?: string
- only one string child is allowed and it must contain code to formatFAQs
Syntax highlighter component for Bobril
The npm package @bobril/highlighter receives a total of 1 weekly downloads. As such, @bobril/highlighter popularity was classified as not popular.
We found that @bobril/highlighter demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers 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.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.