mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-02-12 22:29:41 +08:00
[react-packager] Fixes stack traces
Summary: TransformErrors weren't showing stack traces, making it hard to debug problems in transformer code.
This commit is contained in:
@@ -121,7 +121,9 @@ Transformer.prototype.loadFileAndTransform = function(filePath) {
|
||||
});
|
||||
};
|
||||
|
||||
function TransformError() {}
|
||||
function TransformError() {
|
||||
Error.captureStackTrace && Error.captureStackTrace(this, TransformError);
|
||||
}
|
||||
util.inherits(TransformError, SyntaxError);
|
||||
|
||||
function formatError(err, filename, source) {
|
||||
|
||||
Reference in New Issue
Block a user