Source Maps
Generate source maps files for your CSS and JS.
Options See on deno.land
- inline boolean
Set true to inline the source map in the output file
Default:false
- sourceContent boolean
Set true to include the content of the source files
Default:false
Description
Lume plugins like Postcss, esbuild, Terser, SASS or Lightning CSS process and bundle your CSS and JavaScript files. Combine them with source_maps
to create the source maps files to debug your code in the browser's development tools.
Installation
Import this plugin in your _config.ts
file to use it:
import lume from "lume/mod.ts";
import sass from "lume/plugins/sass.ts";
import postcss from "lume/plugins/postcss.ts";
import esbuild from "lume/plugins/esbuild.ts";
import sourceMaps from "lume/plugins/source_maps.ts";
const site = lume();
// Process your CSS and JS code with other plugins
site.use(sass());
site.use(postcss());
site.use(esbuild());
// Use the source maps plugin to generate the .map files
site.use(sourceMaps(/* Options */));
export default site;