From 13a3ccb2c67a25830918abe586eca0eda8b85bf7 Mon Sep 17 00:00:00 2001 From: Kasper Date: Wed, 10 Mar 2021 23:48:29 +0100 Subject: [PATCH] Enable source maps in dev only --- README.md | 2 +- snowpack.config.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 7bb90c7..40b6b3d 100755 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ Limitations: `src/main.ts` is built and bundled into `build/bundle/`. -To disable source maps, disable `buildOptions.sourceMaps` in `snowpack.config.js`. +To disable source maps, disable `buildOptions.sourcemap` in `snowpack.config.js`. ## Commands diff --git a/snowpack.config.js b/snowpack.config.js index 5e4a4e1..96438a2 100755 --- a/snowpack.config.js +++ b/snowpack.config.js @@ -12,7 +12,7 @@ module.exports = { }, buildOptions: { out: './build', - sourcemap: true, + sourcemap: process.env.NODE_ENV === 'development', clean: true, }, optimize: { -- 2.51.2