-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
103 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,103 @@ | ||
--- | ||
title: 2023/11/13〜2023/11/19の最新情報 | ||
tags: | ||
- Deno | ||
- deno_std | ||
categories: | ||
- news | ||
date: 2023-11-19 | ||
description: Deno v1.38.2, deno_std v0.207.0 | ||
--- | ||
|
||
## Deno v1.38.2 | ||
|
||
[Deno v1.38.2](https://github.com/denoland/deno/releases/tag/v1.38.2)がリリースされました。 | ||
|
||
### `AbortSignal.any`が実装 | ||
|
||
```javascript | ||
const signal1 = AbortSignal.timeout(1000); | ||
const signal2 = new AbortController().signal; | ||
const signal3 = AbortSignal.any([signal1, signal2]); | ||
setTimeout(() => { | ||
console.info(signal3.reason); // => DOMException: Signal timed out. | ||
}, 2000); | ||
``` | ||
|
||
--- | ||
|
||
- [AbortSignal.any(), AbortSignal.timeout(), そして addEvnetListener() の Signal | blog.jxck.io](https://blog.jxck.io/entries/2023-06-01/abort-signal-any.html#abort-handling-practice) | ||
|
||
### `deno lsp`: `vscode-deno`でDenoのアップデートがサポート | ||
|
||
Denoの最新バージョンが見つかった際に、`vscode-deno`からプロンプトが表示されます。 | ||
|
||
- [feat: deno upgrade prompt (denoland/vscode_deno#988)](https://github.com/denoland/vscode_deno/pull/988) | ||
|
||
`deno upgrade`同様、`DENO_NO_UPDATE_CHECK`が設定されていればスキップされます。 | ||
|
||
### Node.js互換性の改善 | ||
|
||
- `node:perf_hooks`: `performance.getEntriesByName()`/`performance.getEntriesByType()`が追加されました。 | ||
- `node:process`: `process.geteuid()`が実装されました。(Windowsでは未定義(`undefined`)になります) | ||
- BYONM: `node_modules`内のCommonJS形式のエントリポイントを提供するパッケージが動作しない問題が修正されました。 | ||
|
||
### その他 | ||
|
||
- `TextDecoderStream`で発生するリソースリークが修正されました。 | ||
- `--strace-ops`オプションが追加されました。実行されたopを追跡できます。 | ||
```shell | ||
$ deno run -A --strace-ops=fs main.js | ||
[ 0.027] op_fs_read_file_text_async: Dispatched Async | ||
[ 0.028] op_fs_read_file_text_async: CompletedAsync Async | ||
``` | ||
|
||
## deno_std v0.207.0 | ||
|
||
[deno_std v0.207.0](https://github.com/denoland/deno_std/releases/tag/0.207.0)がリリースされています。 | ||
|
||
v1のリリースに向けて新しいロードマップ([Roadmap to v1, pt. 2 #3805](https://github.com/denoland/deno_std/issues/3805))が公開されていて、それに向けた作業が進められているようです。 | ||
|
||
### TypeScriptの`enum`が非推奨化 | ||
|
||
`deno_std`で[TypeScriptの`enum`の使用が非推奨化](https://github.com/denoland/deno_std/issues/3782)されています。 | ||
|
||
- [std/fs/eol.ts](https://deno.land/[email protected]/fs/eol.ts): `EOL`が非推奨化されました。 | ||
- 代わりに`LF`/`CRLF`が追加されているため、それらで代用できます。 | ||
- [std/http/status.ts](https://deno.land/[email protected]/http/status.ts): `Status`が非推奨化されました。 | ||
- 代わりに`STATUS_CODE`/`STATUS_TEXT`が追加されているため、それらで代用できます。 | ||
- `isInformationalStatus()`などの各種述語関数も`Status`ではなく`number`を受け取るように変更されています。 | ||
|
||
### 非推奨化されたモジュール/APIの削除 | ||
|
||
以下の非推奨化されたモジュール/APIが削除されました。 | ||
|
||
- `std/wasi` | ||
- `std/http/http_errors.ts` | ||
- `std/crypto/crypto.ts`: `crypto.subtle.timingSafeEqual` | ||
- `std/crypto/timing_safe_equal.ts`は残っていて、そちらは引き続き利用できます。 | ||
|
||
### 既存モジュール/APIの非推奨化 | ||
|
||
以下のモジュール/APIが非推奨化されました。 | ||
|
||
- `std/http/server_sent_event.ts` | ||
- `std/bytes/concat.ts`: スプレッド形式の`concat()` | ||
|
||
### `std/flags`が`std/cli/parse_args.ts`へ移動 | ||
|
||
`std/flags`が`std/cli/parse_args.ts`へ移動されました。 | ||
|
||
今後、CLIに関するAPIはこの`std/cli`に追加されるようです。 | ||
|
||
- [feat(cli): promptSecret() (#3777)](https://github.com/denoland/deno_std/pull/3777) | ||
|
||
### `std/data_structures`が追加 | ||
|
||
元々`std/collections/unstable_*`に配置されていたファイルが`std/data_structures`に移動されています。 | ||
|
||
- `collections/unstable_binary_heap.ts` → `data_structures/binary_heap.ts` | ||
- `collections/unstable_binary_search_tree.ts` → `data_structures/binary_search_tree.ts` | ||
- `collections/unstable_comparators.ts` → `data_structures/comparators.ts` | ||
|
||
この変更に合わせて、`std/collections`の`binary_heap.ts`/`binary_search_tree.ts`/`red_black_tree.ts`が非推奨化されています。 |