Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Why cache namespaces?

オープン
#974 コメント 0 件 リアクション 2 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
20/100
issue の種類
バグ
明瞭さ
説明が足りない
活発さ
停滞
技術スタック
javascript
領域
frontend

調査の方向性

Start by tracing the browser localStorage path that loads enabled namespaces, then compare it with the debug.store behavior and the VITE_DEBUG_ENABLE initialization shown in the issue. The issue names no files or tests; completion depends on deciding the intended cache behavior and confirming it across page loads.

索引モデルが issue の本文から書いたものです。

説明

I do not understand why localstorage is used to cache the enabled namespaces. It seems to just cause confusion with unexpected behavior. #901 #536 #871 #534 #337

I had to spend some time to figure out why

if (process.env.VITE_DEBUG_ENABLE)
    debug.enable(process.env.VITE_DEBUG_ENABLE);

didn't work when I removed the env var. I expected each page load to be an isolated environment until I managed to step through the code and see its caching. I tried to disable storage with debug.store = null but that didn't prevent the initial load.

debug.enable(process.env.VITE_DEBUG_ENABLE ?? '');

is where I landed, which admittedly isn't complicated, but its weird that I had to deal with this problem.

主要言語
JavaScript
スター
11.5k
フォーク
993
PR マージ指標
30日以内にマージされた PR はありません

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

debug-js/debug のほかの issue

debug-js/debug の issue をすべて見る

似ている issue

JavaScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。