arethetypeswrong / arethetypeswrong/arethetypeswrong.github.io

Report invalid `module` field in `package.json`

オープン
#68 コメント 2 件 リアクション 2 件 担当者 0 名 GitHub で見る
主要言語
TypeScript
スター
1.6k
フォーク
65
PR マージ指標
30日以内にマージされた PR はありません

説明

Some packages define the top-level `module` field in `package.json`. Although it’s non-standard, bundlers use it. This can lead to differences between usage in the browser and Node.js, but it is not possible to add type definitions for it.

I think it would be useful to report the `module` field if it does not match the `import` condition in the `package.json` `exports` field nor the `main` field.

For example:

- [`monaco-editor`](https://github.com/microsoft/monaco-editor/blob/main/package.json#L34)
- [`vscode-json-languageservice`](https://github.com/microsoft/vscode-json-languageservice/blob/main/package.json#L7)
- [`vscode-uri`](https://github.com/microsoft/vscode-uri/blob/main/package.json#L8)
- [`whatwg-fetch`](https://github.com/JakeChampion/fetch/blob/master/package.json#L6)

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

調査の方向性

まず、package.json のメタデータがどのように解析されるかを追跡し、ここで説明されている module フィールド、exports の import condition、main フィールドに焦点を当てます。module がこれらのフィールドと一致しないパッケージが報告されれば完了です。記載された例のパッケージは動作の確認に役立ちます。

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

評価

技術スタック
typescript
領域
tooling
issue の種類
機能追加
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
45/100

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

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