From 46f893bda0164d751cf1cbe76bfb5de236390237 Mon Sep 17 00:00:00 2001 From: Dan Wolff Date: Mon, 5 Feb 2018 21:30:46 +0100 Subject: [PATCH] add note on debugging with source maps --- README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/README.md b/README.md index 51ab74e4..f06ae0af 100644 --- a/README.md +++ b/README.md @@ -1117,3 +1117,11 @@ To allow for better optimizations, the compiler makes various assumptions. - Object properties are able to be added (not prevented with `Object.defineProperty()`, `Object.defineProperties()`, `Object.freeze()`, `Object.preventExtensions()` or `Object.seal()`). + +### Source maps and debugging + +Various `compress` transforms that simplify, rearrange, inline and remove code +are known to have an adverse effect on debugging with source maps. This is +expected as code is optimized and mappings are often simply not possible as +some code no longer exists. For highest fidelity in source map debugging +disable the Uglify `compress` option and just use `mangle`.