Skip to content

zely 1.1 has been published. No features have been added, but something very important has been updated.

Source Map

I've been thinking about how to make errors easier to see.
In fact, when printing an error in prext 2.1, the original file is also printed. However, it only provided the file path, but you couldn't figure out which line or column the error occurred.

But now zely tells you via source-map which file, on which line, and on which line the error occurred.

Here is some code.
This is simple code that throws an error as soon as the request is received.

ts
export function get() {
  throw new Error('Something wrong');
}
export function get() {
  throw new Error('Something wrong');
}

Output:

  • In 1.0.4
[10:00:00 PM] [tracer] Error occurred in /pages/error.ts
[10:00:00 PM] [tracer] Error occurred in /pages/error.ts
  • In 1.1.0
pages\error.ts:2:8
1 | export function get() {
2 |   throw new Error('Something wrong');
3 | }
pages\error.ts:2:8
1 | export function get() {
2 |   throw new Error('Something wrong');
3 | }

Playground

You can try this feature right away - /playground/error-mapping