mirror of
https://github.com/edu4rdshl/gnome-shell.git
synced 2026-07-17 23:24:51 +00:00
js: Add utility to improve error message formatting
Previously, when we formatted SyntaxErrors with toString(), they wouldn't display the file/line/column where the syntax error occurred. This adds a utility function that performs a more comprehensive formatting that displays location information for SyntaxErrors, as well as the .cause property of the error if it is present. This formatting is equivalent to what we do in gjs-console when logging an error. Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3041>
This commit is contained in:
parent
5fe6e5c865
commit
a1a320d3d1
2 changed files with 63 additions and 0 deletions
|
|
@ -19,6 +19,7 @@
|
|||
<file>misc/dateUtils.js</file>
|
||||
<file>misc/dbusUtils.js</file>
|
||||
<file>misc/dependencies.js</file>
|
||||
<file>misc/errorUtils.js</file>
|
||||
<file>misc/extensionUtils.js</file>
|
||||
<file>misc/fileUtils.js</file>
|
||||
<file>misc/gnomeSession.js</file>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue