Inicio

Using MDX

Lorem ipsum dolor sit amet

This theme comes with the @astrojs/mdx integration installed and configured in your astro.config.mjs config file. If you prefer not to use MDX, you can disable support by removing the integration from your config file.

Why MDX?

MDX is a special flavor of Markdown that supports embedded JavaScript & JSX syntax. This unlocks the ability to mix JavaScript and UI Components into your Markdown content for things like interactive charts or alerts.

If you have existing content authored in MDX, this integration will hopefully make migrating to Astro a breeze.

Example

Here is how you import and use a UI component inside of MDX.
When you open this page in the browser, you should see the clickable button below.

Embedded component in MDX

Líneas: datos medidos

A line chart accepts numeric { x, y } values. Hover a line or its legend item to isolate it.

Visualizaciones semanales
0127.5255382.551001.534.56SemanaVisualizaciones

Líneas: sin puntos ni cuadrícula

Use showPoints={false} and showGrid={false} for a quieter chart.

Tiempo de renderizado optimizado
01734516801.252.53.755VersiónSegundos

Líneas: toggle de dos estados

A line chart can optionally cycle between two states with one toggle.

Calidad de imagen
0367210814401234EscenaAVG FPS

Curvas: funciones

A curve chart samples a JavaScript function across xDomain, which is useful for benchmarks and projections.

Tiempo de renderizado
012.2524.536.754902.557.510ComplejidadSegundos

Curvas: funciones matemáticas

Functions can also describe waves, thresholds, or other models.

Modelos de señal
-10-50510036912TiempoAmplitud

Barras: comparar categorías

Use bar for grouped vertical bars. Each point’s x value becomes a category label.

Coste del proyecto
0750150022503000EquipoRodajePostPartidaEuros

Torre: una serie de costes

tower is a compact alias for a single-series vertical cost graph.

Coste mensual
0175350525700EneFebMarAbrMayMesEuros

Rendimiento por vatio: GPUs modernas

Cada punto representa una GPU en un juego concreto. El eje X muestra el consumo en vatios y el eje Y los FPS medios; al pasar por encima de un punto aparece el juego y el resultado exacto.

Rendimiento por vatio en GPUs
060120180240100237.5375512.5650VatiosAVG FPS

Log picture profiles

Calidad de imagen
02.557.51002.557.510EscenaAVG FPS

Tabla: comparar resultados

Las tablas Markdown funcionan directamente en archivos .mdx y reciben el estilo de la página.

GPU Consumo AVG FPS FPS/W
RTX 5090 575 W 202 0.35
RTX 5080 360 W 178 0.49
RTX 5070 Ti 300 W 159 0.53
RX 9070 XT 304 W 171 0.56
Arc B580 190 W 109 0.57