From 9ba5c0f9ba76a38c3a71ac587b259f230406fa80 Mon Sep 17 00:00:00 2001 From: bcoe Date: Sat, 13 Feb 2021 12:19:04 -0800 Subject: [PATCH] errors: remove experimental from --enable-source-maps PR-URL: https://github.com/nodejs/node/pull/37362 Reviewed-By: Rich Trott Reviewed-By: Ian Sutherland Reviewed-By: Luigi Pinca Reviewed-By: Antoine du Hamel Reviewed-By: Michael Dawson Reviewed-By: Richard Lau Reviewed-By: Jiawen Geng Reviewed-By: Beth Griggs --- doc/api/cli.md | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/doc/api/cli.md b/doc/api/cli.md index 70cb69cd54a451..c9f51b65f94cc7 100644 --- a/doc/api/cli.md +++ b/doc/api/cli.md @@ -192,14 +192,21 @@ Enable FIPS-compliant crypto at startup. (Requires Node.js to be built with ### `--enable-source-maps` -> Stability: 1 - Experimental +Enable [Source Map v3][Source Map] support for stack traces. -Enable experimental Source Map v3 support for stack traces. +When using a transpiler, such as TypeScript, strack traces thrown by an +application reference the transpiled code, not the original source position. +`--enable-source-maps` enables caching of Source Maps and makes a best +effort to report stack traces relative to the original source file. -Currently, overriding `Error.prepareStackTrace` is ignored when the -`--enable-source-maps` flag is set. +Overriding `Error.prepareStackTrace` prevents `--enable-source-maps` from +modifiying the stack trace. ### `--experimental-abortcontroller`