Stop using :even/:odd in examples on other pages
まだ誰も着手していません。
評価
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 初心者へのやさしさ
- 35/100
- issue の種類
- ドキュメント
- 明瞭さ
- 説明が足りない
- 活発さ
- 停滞
- 技術スタック
- jquery
調査の方向性
PR #1145 と、まだ :odd または :even を使用している API ページの例を確認します。まず、提案されている .even()/.odd() API を jQuery 3.5.0 に導入すべきかどうかを判断し、導入しない場合は、それらの例を別のアプローチを使うように書き換えます。意思決定が記録され、残りの例が非推奨のセレクターに依存しなくなれば完了です。
索引モデルが issue の本文から書いたものです。
説明
PR #1145 marked all positional selectors as deprecated & removed their usage from API pages for non-deprecated APIs. The only exceptions are :even & :odd selectors as there are no tiny equivalents in jQuery APIs.
We could define an .even()/.odd() API. This is the implementation that adds +25 bytes: https://github.com/mgol/jquery/commit/f45409708c6f307bf923440d09f6f2fd86df9a9d
even: function() {
return this.filter( function( i ) {
return ( i + 1 ) % 2;
} );
},
odd: function() {
return this.filter( function( i ) {
return i % 2;
} );
},
That said, such an API would be jQuery 3.5.0+ (unless Migrate polyfills it for earlier versions as well) only and we'd have to release that 3.5.0 before 4.0.0. Something to consider.
If that's decided against then we need to rewrite existing examples using :odd/:even to use something else.
I think I'm slightly in favor of introducing these two new methods as that'd close the gap from POS selectors & it'd simplify the migration. But let's talk about it. cc @jquery/core
- 主要言語
- HTML
- スター
- 324
- フォーク
- 259
- 平均マージ
- 1日 30分
- マージ済み PR(30日)
- 1
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
jquery/api.jquery.com のほかの issue
-
Mention of ‘timestamp’ in documentation for ‘cache’ parameter of ‘ajax’ is misleading対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 62/100
jquery/api.jquery.com#1241 · コメント 2 件 ·
-
難易度 1/5 1時間未満 初心者へのやさしさ 68/100
jquery/api.jquery.com#1176 ·
-
The documentation of CSS methods should be further classified再び着手できるかも このイシューのプルリクエストはマージされずにクローズされました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 35/100
jquery/api.jquery.com#1281 · コメント 2 件 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 35/100
jquery/api.jquery.com#1271 · コメント 2 件 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 45/100
jquery/api.jquery.com#1259 ·
jquery/api.jquery.com の issue をすべて見る
似ている issue
-
5-minutes algorithm all-levels any-language beginner-friendly community documentation easy first-timers-only good first issue hacktoberfest help wanted learning no-code-needed open-source python students
難易度 2/5 1時間未満 初心者へのやさしさ 88/100
Huerte/algo-solutions-python#253 ·
メンテナーはふだん 1 日以内に返信
-
size/s
難易度 1/5 1時間未満 初心者へのやさしさ 90/100
sipyourdrink-ltd/bernstein#7179 ·
メンテナーはふだん 1 日以内に返信
-
area/docs
難易度 1/5 1時間未満 初心者へのやさしさ 86/100
meshery/meshery#23375 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Synthetic
難易度 1/5 1時間未満 初心者へのやさしさ 66/100
samtoth/agda-synthetic-categories#373 ·
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 62/100
tanaabased/big-test-bucket#19952 ·
メンテナーはふだん 1 日以内に返信