
Security News
The Hidden Blast Radius of the Axios Compromise
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.
@bodystyle/show-code
Advanced tools
Acerca de • Inicio Rápido • Instalación • Uso • Temas • Contribuir • Licencia
Show Code es una biblioteca JavaScript liviana y eficiente para resaltar sintaxis de código en páginas web. Es una dependencia de BodyStyle, diseñada para proporcionar funcionalidades de resaltado de código de manera simple y elegante.
La forma más rápida de usar Show Code es mediante CDN:
<!DOCTYPE html>
<html lang="es">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!-- Tema claro -->
<link rel="stylesheet" href="https://rawcdn.githack.com/FedeManzano/show-sintax/refs/heads/master/dist/css/tema-claro.min.css">
<!-- Tema oscuro -->
<link rel="stylesheet" href="https://rawcdn.githack.com/FedeManzano/show-sintax/refs/heads/master/dist/css/tema-oscuro.min.css">
<title>Show Code Demo</title>
</head>
<body>
<pre class="cod-js">
// Código JavaScript
console.log("¡Hola Mundo!");
</pre>
<script src="https://rawcdn.githack.com/FedeManzano/show-sintax/refs/heads/master/dist/js/sintax.min.js"></script>
<script>
Show.ShowJsInit()
</script>
</body>
</html>
npm install @bodystyle/show-code
<!-- CSS - Tema Oscuro -->
<link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/FedeManzano/show-code@main/dist/css/tema-oscuro.css">
<!-- CSS - Tema Claro -->
<link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/FedeManzano/show-code@main/dist/css/tema-claro.css">
<!-- JavaScript -->
<script src="https://cdn.jsdelivr.net/gh/FedeManzano/show-code@main/dist/js/sintax.js"></script>
Descarga los archivos desde el repositorio de GitHub y copia los archivos de la carpeta dist a tu proyecto.
<link rel="stylesheet" href="ruta/a/tema-oscuro.css">
<script src="ruta/a/sintax.js"></script>
Usa la etiqueta <pre> con la clase correspondiente al lenguaje:
<!-- JavaScript -->
<pre class="cod-js">
const mensaje = "Hola Mundo";
console.log(mensaje);
</pre>
<!-- Java -->
<pre class="cod-java">
public class Main {
public static void main(String[] args) {
System.out.println("Hola Mundo");
}
}
</pre>
<!-- HTML -->
<pre class="cod-html">
<div class="container">
<h1>Título</h1>
<p>Párrafo de ejemplo</p>
</div>
</pre>
<!-- CSS -->
<pre class="cod-css">
.container {
max-width: 1200px;
margin: 0 auto;
padding: 20px;
}
</pre>
<!-- C -->
<pre class="cod-c">
#include <stdio.h>
int main() {
printf("Hola Mundo\n");
return 0;
}
</pre>
<!-- SQL -->
<pre class="cod-sql">
SELECT id, nombre, email
FROM usuarios
WHERE estado = 'activo'
ORDER BY fecha_registro DESC;
</pre>
<script>
// Inicializar todos los lenguajes
Show.ShowJavaInit()
Show.ShowJsInit()
Show.ShowHtmlInit()
Show.ShowCssInit()
Show.ShowCInit()
Show.ShowSqlInit()
</script>
O inicializa solo los lenguajes que necesites:
<script>
// Solo JavaScript
Show.ShowJsInit()
</script>
Show Code incluye dos temas predefinidos:
<link rel="stylesheet" href="dist/css/tema-oscuro.css">
<link rel="stylesheet" href="dist/css/tema-claro.css">
npm install
# Modo desarrollo
npm run dev
# Build de producción
npm run build
Las contribuciones son bienvenidas. Si deseas contribuir:
git checkout -b feature/AmazingFeature)git commit -m 'Add some AmazingFeature')git push origin feature/AmazingFeature)Este proyecto está bajo la Licencia MIT. Ver el archivo LICENSE para más detalles.
Federico Manzano
Hecho con :heart: por Federico Manzano
FAQs
Librería para resaltar el código fuente
We found that @bodystyle/show-code demonstrated a healthy version release cadence and project activity because the last version was released less than 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.

Security News
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.

Research
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.

Research
Malicious versions of the Telnyx Python SDK on PyPI delivered credential-stealing malware via a multi-stage supply chain attack.