binaryage / binaryage/cljs-devtools
Detection of support for custom formatters doesn't work
- 主要言語
- Clojure
- スター
- 1.1k
- フォーク
- 51
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
Hi,
The mechanism used to detect support for custom formatters doesn't work. It will always report that custom formatters are not supported or that support is disabled. This is due to the fact that the detection mechanism relies on the application of a custom formatter when strings are logged to the console. However, custom formatters are not applied when logging strings. They are only applied when logging objects.
Executing the following statements in the console will demonstrate this:
```
window.devtoolsFormatters = [{"header": () => {console.count("formatter"); return null;}}]
console.log("string")
console.log({})
```
You'll see that the counter "formatter" is only increased once, when the last statement is executed. I see the same behavior using both Chrome and Firefox.
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
調査の方向性
Reproduce the issue with the window.devtoolsFormatters and console.log statements shown in the report, using Chrome or Firefox. Locate the detection mechanism that applies a custom formatter during logging and trace how it determines support. Done means detection no longer reports custom formatters as unsupported or disabled when object formatting is available.
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- clojure
- 領域
- tooling
- issue の種類
- バグ
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 48/100