You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Errors for use of non stable APIs are non-obvious. For example:
$ deno run --allow-read --allow-write main.ts
Compile file:///dev/deno/main.ts
Download https://deno.land/std@0.50.0/fs/copy.ts
Download https://deno.land/std@0.50.0/fs/ensure_dir.ts
Download https://deno.land/std@0.50.0/fs/_util.ts
error: TS2339 [ERROR]: Property 'utime' does not exist on type 'typeof Deno'.
await Deno.utime(dest, statInfo.atime, statInfo.mtime);
~~~~~
at https://deno.land/std@0.50.0/fs/copy.ts:90:16
Is there a way that we could include the unstable types at runtime where they could be checked (but not used) when errors of type Property xyz does not exist... occur to provide a more helpful error message?
That would allow us to output something like:
$ deno run --allow-read --allow-write main.ts
Compile file:///dev/deno/main.ts
Download https://deno.land/std@0.50.0/fs/copy.ts
Download https://deno.land/std@0.50.0/fs/ensure_dir.ts
Download https://deno.land/std@0.50.0/fs/_util.ts
error: TS2339 [ERROR]: Property 'utime' does not exist on type 'typeof Deno'.
'utime' is an unstable property of Deno. Add the --unstable flag to enable use.
await Deno.utime(dest, statInfo.atime, statInfo.mtime);
~~~~~
at https://deno.land/std@0.50.0/fs/copy.ts:90:16
The text was updated successfully, but these errors were encountered:
Errors for use of non stable APIs are non-obvious. For example:
Is there a way that we could include the unstable types at runtime where they could be checked (but not used) when errors of type
Property xyz does not exist...
occur to provide a more helpful error message?That would allow us to output something like:
The text was updated successfully, but these errors were encountered: