[Content]: misleading section about when derived-signals are called
まだ誰も着手していません。
評価
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 初心者へのやさしさ
- 45/100
- issue の種類
- ドキュメント
- 明瞭さ
- 明確に書かれている
- 活発さ
- 停滞
- 技術スタック
- javascript
調査の方向性
issue にリンクされている derived-signals のドキュメントページから始め、引用されている説明と、提供されている SolidJS の再現例を比較します。関数がいつ実行されるかを正確に説明するよう文言を更新し、その後、ドキュメント内の例と結果として生じる挙動を検証します。
索引モデルが issue の本文から書いたものです。
説明
📚 Subject area/topic
concepts/derived-values/derived-signals
📋 Page(s) affected (or suggested, for new content)
https://docs.solidjs.com/concepts/derived-values/derived-signals
📋 Description of content that is out-of-date or incorrect
These functions are not executed immediately, but instead are only called when the values they rely on are changed. When the underlying signal is changed, the function will be called again to produce a new value.
I'm beginning with solidjs, so maybe I got this wrong, but I think this is at least misleading.
It is not called when count() changed (click "call inc").
It is only called, if it is explicitly called (in the example click "call double") or if it is used in a reactive context (uncomment {/*<div>double: {double()}</div>*/})
🖥️ Reproduction in StackBlitz (if reporting incorrect content or code samples)
import { render } from "solid-js/web";
import { createSignal } from "solid-js";
function App() {
const [count, setCount] = createSignal(0);
const inc = () => setCount(count() + 1)
const double = () => {console.log("double called"); return count() * 2}
return (
<div>
<div>count: {count()}</div>
{/*<div>double: {double()}</div>*/}
<button onClick={() => inc()}>call inc</button>
<button onClick={() => double()}>call double</button>
</div>
);
}
render(() => <App />, document.getElementById('app'));
- 主要言語
- MDX
- スター
- 292
- フォーク
- 361
- 平均マージ
- 7時間 51分
- マージ済み PR(30日)
- 1
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
solidjs/solid-docs のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
solidjs/solid-docs#1635 ·
-
good first issue solid solidstart
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
solidjs/solid-docs#1522 ·
-
pending review
solidjs/solid-docs#1637 · 担当者 1 名 ·
-
help wanted
solidjs/solid-docs#1636 · コメント 4 件 ·
-
難易度 3/5 1〜2日 初心者へのやさしさ 52/100
solidjs/solid-docs#1630 · コメント 1 件 ·
solidjs/solid-docs の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
palladius/rails8-app-on-gcp#145 ·
-
NeedsTriage
難易度 1/5 1時間未満 初心者へのやさしさ 90/100
-
error オープン
難易度 1/5 1時間未満 初心者へのやさしさ 85/100
-
難易度 1/5 1時間未満 初心者へのやさしさ 85/100
-
textual definition
難易度 1/5 1時間未満 初心者へのやさしさ 90/100
geneontology/go-ontology#32653 ·