Skip to content

Commit fd3e25b

Browse files
authored
Changelog v2.0.0 (#1254)
* Add 2.0.0 changelog entry * Add new maintainers section to backlog * Lower Node engine back down * Add Node 16 to back CI * Add links, fix typos * Fixup heading level * Fix typos * Changelog edits
1 parent fdf3e62 commit fd3e25b

File tree

3 files changed

+35
-2
lines changed

3 files changed

+35
-2
lines changed

.github/workflows/ci.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ jobs:
55
runs-on: ubuntu-latest
66
strategy:
77
matrix:
8-
node-version: [18.x, 20.x, 22.x]
8+
node-version: [16.x, 18.x, 20.x, 22.x]
99
steps:
1010
- uses: actions/checkout@v4
1111
- uses: actions/setup-node@v4

Changelog.md

+33
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,39 @@
22

33
This document maintains a list of major changes to Superstruct with each new release.
44

5+
### `2.0.0` - July 3, 2024
6+
7+
Some changes in Superstruct v2.0 are _potentially_ breaking if you were using the library in unusual and/or undocumented ways. Since it has been almost 2 years since the last significant release, we want to make sure that we don't ruin someone's day by surprising them with a fix that changes [buggy behavior they were relying on](https://xkcd.com/1172/). For this reason, some changes that would ordinarily be considered a fix are marked as breaking.
8+
9+
**:rocket: For the absolute majority of users, this should be a smooth upgrade that will not require any changes.**
10+
11+
#### Breaking
12+
13+
- Validation now correctly fails when arrays are passed to `object()`, `type()`, and `record()` structs.
14+
- When coercing an `object()` (via `mask()`, `create()` or `validate()` with the `coerce: true` option), arrays will no longer be automatically converted to objects with indexes as keys. [See this PR comment](https://github.com/ianstormtaylor/superstruct/pull/1196#issuecomment-1858924264).
15+
16+
#### New
17+
18+
- The library and its TypeScript typings are now compatible with NodeNext/Node16 module resolution. This means that if you are using the library with TypeScript and ECMAScript modules at the same time, you should no longer run into issues!
19+
20+
#### Fixed
21+
22+
- Using `mask()` with `union()` now correctly masks union members instead of incorrectly failing validation.
23+
24+
#### Deprecations
25+
26+
- Use with Node.js v14 is now deprecated. Due to incompatible tooling, we are no longer able to test Superstruct on this version of Node.js. Use at your own risk.
27+
28+
#### New Maintainers & Next Steps
29+
30+
Project maintenance has moved to a new volunteer team: [@arturmuller](https://github.com/arturmuller) and [@yeoffrey](https://github.com/yeoffrey). Hello there! :wave: We are currently going through the existing issues and PRs, trying to resolve or close the backlog. This might take a little while so please bear with us.
31+
32+
If you are interested in **contributing** — or helping us process the backlog — we would love your help. Don't hesitate to help us triage, open an issue, or submit a PR. You can also join our Superstruct maintainers Discord: https://discord.gg/pdHrQBjQ96.
33+
34+
If you have **questions, suggestions, or are just not sure about something** related to Superstruct, head over to GitHub Discussions! We have recently enabled this feature to help us differentiate between actual issues/bugs and everything else. We hope this will be a great new place where Superstruct users can get quick help from us — the maintainers — but also from the community as a whole.
35+
36+
See you at the next release! :v:
37+
538
### `1.0.0` — November 17, 2022
639

740
###### NEW

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
"registry": "https://registry.npmjs.org"
1717
},
1818
"engines": {
19-
"node": ">=18.0.0"
19+
"node": ">=14.0.0"
2020
},
2121
"devDependencies": {
2222
"@babel/cli": "^7.6.3",

0 commit comments

Comments
 (0)