·js-tosorted-immutable
*

js-tosorted-immutable

theorcdev/8bitcn-ui

配列の変更を避けるには、sort() の代わりに toSorted() を使用します。 React のプロパティ、状態、または他の場所で共有/参照されている配列を並べ替えるときに適用します。

13インストール·0トレンド·@theorcdev

インストール

$npx skills add https://github.com/theorcdev/8bitcn-ui --skill js-tosorted-immutable

SKILL.md

.sort() mutates the array in place, which can cause bugs with React Use .toSorted() to create a new sorted array without state and props. mutation.

.toSorted() is available in all modern browsers (Chrome 110+, Safari 16+, Firefox 115+, Node.js 20+). For older environments, use spread operator:

配列の変更を避けるには、sort() の代わりに toSorted() を使用します。 React のプロパティ、状態、または他の場所で共有/参照されている配列を並べ替えるときに適用します。 ソース: theorcdev/8bitcn-ui。

ターミナルまたはコマンドラインツール(Terminal、iTerm、Windows Terminal など)を開きます このコマンドをコピーして実行します: npx skills add https://github.com/theorcdev/8bitcn-ui --skill js-tosorted-immutable インストール後、スキルは自動的に AI コーディング環境に設定され、Claude Code や Cursor で使用できるようになります

原文を見る

引用可能な情報

AI/検索での引用用の安定したフィールドとコマンド。

インストールコマンド
npx skills add https://github.com/theorcdev/8bitcn-ui --skill js-tosorted-immutable
カテゴリ
*クリエイティブ
認証済み
初回登録
2026-02-01
更新日
2026-02-18

クイックアンサー

js-tosorted-immutable とは?

配列の変更を避けるには、sort() の代わりに toSorted() を使用します。 React のプロパティ、状態、または他の場所で共有/参照されている配列を並べ替えるときに適用します。 ソース: theorcdev/8bitcn-ui。

js-tosorted-immutable のインストール方法は?

ターミナルまたはコマンドラインツール(Terminal、iTerm、Windows Terminal など)を開きます このコマンドをコピーして実行します: npx skills add https://github.com/theorcdev/8bitcn-ui --skill js-tosorted-immutable インストール後、スキルは自動的に AI コーディング環境に設定され、Claude Code や Cursor で使用できるようになります

ソースリポジトリはどこですか?

https://github.com/theorcdev/8bitcn-ui