Skip to content

Commit b71b7a6

Browse files
authored
Merge pull request #75 from arethetypeswrong/changeset-release/main
Version Packages
2 parents a558fcd + 895a3da commit b71b7a6

8 files changed

+95
-23
lines changed

.changeset/good-glasses-wait.md

Lines changed: 0 additions & 11 deletions
This file was deleted.

.changeset/loud-hairs-relate.md

Lines changed: 0 additions & 9 deletions
This file was deleted.

packages/cli/CHANGELOG.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,20 @@
11
# @arethetypeswrong/cli
22

3+
## 0.8.0
4+
5+
### Minor Changes
6+
7+
- 894d0f3: Add support for DefinitelyTyped analysis.
8+
9+
- `@types` packages will be fetched by default for implementation packages that do not contain any TypeScript files.
10+
- `--definitely-typed` can be used to set the version of the `@types` package fetched. By default, the version is inferred from the implementation package version.
11+
- `--no-definitely-typed` can be used to prevent `@types` package inclusion.
12+
13+
### Patch Changes
14+
15+
- Updated dependencies [894d0f3]
16+
- @arethetypeswrong/core@0.8.0
17+
318
## 0.7.1
419

520
### Patch Changes

packages/cli/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@arethetypeswrong/cli",
3-
"version": "0.7.1",
3+
"version": "0.8.0",
44
"description": "A CLI tool for arethetypeswrong.github.io",
55
"author": "Andrew Branch & ej-shafran",
66
"contributors": [
@@ -45,7 +45,7 @@
4545
"typescript": "^5.0.0-dev.20230207"
4646
},
4747
"dependencies": {
48-
"@arethetypeswrong/core": "0.7.0",
48+
"@arethetypeswrong/core": "0.8.0",
4949
"chalk": "^4.1.2",
5050
"cli-table3": "^0.6.3",
5151
"commander": "^10.0.1",
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# [email protected] --definitely-typed /home/runner/work/arethetypeswrong.github.io/arethetypeswrong.github.io/packages/core/test/fixtures/@[email protected]
2+
3+
```
4+
$ attw [email protected] --definitely-typed /home/runner/work/arethetypeswrong.github.io/arethetypeswrong.github.io/packages/core/test/fixtures/@[email protected]
5+
6+
7+
big.js v6.2.1
8+
@types/big.js v6.2.0
9+
10+
🎭 Import resolved to a CommonJS type declaration file, but an ESM JavaScript file. https://github.com/arethetypeswrong/arethetypeswrong.github.io/blob/main/docs/problems/FalseCJS.md
11+
12+
❌ Import resolved to JavaScript files, but no type declarations were found. https://github.com/arethetypeswrong/arethetypeswrong.github.io/blob/main/docs/problems/UntypedResolution.md
13+
14+
⚠️ A require call resolved to an ESM JavaScript file, which is an error in Node and some bundlers. CommonJS consumers will need to use a dynamic import. https://github.com/arethetypeswrong/arethetypeswrong.github.io/blob/main/docs/problems/CJSResolvesToESM.md
15+
16+
17+
┌───────────────────┬────────────────────────┬──────────────────────────────┬─────────────────┬───────────────────────┐
18+
│ │ "big.js" │ "big.js/big.mjs" │ "big.js/big.js" │ "big.js/package.json" │
19+
├───────────────────┼────────────────────────┼──────────────────────────────┼─────────────────┼───────────────────────┤
20+
│ node10 │ 🟢 │ ❌ No types │ ❌ No types │ 🟢 (JSON) │
21+
├───────────────────┼────────────────────────┼──────────────────────────────┼─────────────────┼───────────────────────┤
22+
│ node16 (from CJS) │ 🟢 (CJS) │ ❌ No types │ ❌ No types │ 🟢 (JSON) │
23+
│ │ │ ⚠️ ESM (dynamic import only) │ │ │
24+
├───────────────────┼────────────────────────┼──────────────────────────────┼─────────────────┼───────────────────────┤
25+
│ node16 (from ESM) │ 🎭 Masquerading as CJS │ ❌ No types │ ❌ No types │ 🟢 (JSON) │
26+
├───────────────────┼────────────────────────┼──────────────────────────────┼─────────────────┼───────────────────────┤
27+
│ bundler │ 🟢 │ ❌ No types │ ❌ No types │ 🟢 (JSON) │
28+
└───────────────────┴────────────────────────┴──────────────────────────────┴─────────────────┴───────────────────────┘
29+
30+
31+
```
32+
33+
Exit code: 1
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# [email protected] --definitely-typed /home/runner/work/arethetypeswrong.github.io/arethetypeswrong.github.io/packages/core/test/fixtures/@[email protected]
2+
3+
```
4+
$ attw [email protected] --definitely-typed /home/runner/work/arethetypeswrong.github.io/arethetypeswrong.github.io/packages/core/test/fixtures/@[email protected]
5+
6+
7+
react v18.2.0
8+
@types/react v18.2.21
9+
10+
No problems found 🌟
11+
12+
13+
┌─────────────────────────┬───────────┬───────────────────┬───────────────────┬───────────┐
14+
│ │ node10 │ node16 (from CJS) │ node16 (from ESM) │ bundler │
15+
├─────────────────────────┼───────────┼───────────────────┼───────────────────┼───────────┤
16+
│ "react" │ 🟢 │ 🟢 (CJS) │ 🟢 (CJS) │ 🟢 │
17+
├─────────────────────────┼───────────┼───────────────────┼───────────────────┼───────────┤
18+
│ "react/package.json" │ 🟢 (JSON) │ 🟢 (JSON) │ 🟢 (JSON) │ 🟢 (JSON) │
19+
├─────────────────────────┼───────────┼───────────────────┼───────────────────┼───────────┤
20+
│ "react/jsx-runtime" │ 🟢 │ 🟢 (CJS) │ 🟢 (CJS) │ 🟢 │
21+
├─────────────────────────┼───────────┼───────────────────┼───────────────────┼───────────┤
22+
│ "react/jsx-dev-runtime" │ 🟢 │ 🟢 (CJS) │ 🟢 (CJS) │ 🟢 │
23+
├─────────────────────────┼───────────┼───────────────────┼───────────────────┼───────────┤
24+
│ "react/canary" │ 🟢 │ 🟢 (CJS) │ 🟢 (CJS) │ 🟢 │
25+
├─────────────────────────┼───────────┼───────────────────┼───────────────────┼───────────┤
26+
│ "react/experimental" │ 🟢 │ 🟢 (CJS) │ 🟢 (CJS) │ 🟢 │
27+
└─────────────────────────┴───────────┴───────────────────┴───────────────────┴───────────┘
28+
29+
30+
```
31+
32+
Exit code: 0

packages/core/CHANGELOG.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,17 @@
11
# @arethetypeswrong/core
22

3+
## 0.8.0
4+
5+
### Minor Changes
6+
7+
- 894d0f3: Add support for DefinitelyTyped analysis.
8+
9+
- `createPackageFromNpm` now takes an options parameter that can control DefinitelyTyped inclusion.
10+
- The `Package` type is now a class, with new properties and methods:
11+
- `typesPackage` contains the package name and version for the included DefinitelyTyped package, if any.
12+
- `mergedWithTypes(typesPackage: Package)` returns a new `Package` instance with all files from both packages and the `typesPackage` instance property metadata filled in.
13+
- `createPackageFromTarballData` is no longer asynchronous.
14+
315
## 0.7.0
416

517
### Minor Changes

packages/core/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@arethetypeswrong/core",
3-
"version": "0.7.0",
3+
"version": "0.8.0",
44
"description": "The API behind arethetypeswrong.github.io",
55
"author": "Andrew Branch",
66
"license": "MIT",

0 commit comments

Comments
 (0)