@metamask-previews/base-controller
Advanced tools
Comparing version 4.1.1-preview.8cdddaf to 4.1.1-preview.91dd28a
# Changelog | ||
All notable changes to this project will be documented in this file. | ||
@@ -10,7 +11,11 @@ | ||
## [4.1.1] | ||
### Changed | ||
- Bump `@metamask/utils` to `^8.3.0` ([#3769](https://github.com/MetaMask/core/pull/3769)) | ||
## [4.1.0] | ||
### Added | ||
- Add `registerInitialEventPayload` to `ControllerMessenger` and `RestrictedControllerMessenger` ([#3697](https://github.com/MetaMask/core/pull/3697)) | ||
@@ -20,2 +25,3 @@ - This allows registering an event payload function for an event, which has the benefit of ensuring the "subscription selector" feature works correctly the first time the event is fired after subscribing. | ||
### Fixed | ||
- Fix `subscribe` method selector support on first publish ([#3697](https://github.com/MetaMask/core/pull/3697)) | ||
@@ -28,3 +34,5 @@ - An event with a registered initial event payload function will work better with selectors, in that it will correctly compare with the initial selected state and return the previous value the first time it's published. Without this, the initial published event will always return `undefined` as the previous value. | ||
## [4.0.1] | ||
### Changed | ||
- Deprecate `subscribe` property from `BaseControllerV2` ([#3590](https://github.com/MetaMask/core/pull/3590), [#3698](https://github.com/MetaMask/core/pull/3698)) | ||
@@ -34,3 +42,5 @@ - This property was used to differentiate between `BaseControllerV1` and `BaseControllerV2` controllers. It is no longer used, so it has been marked as deprecated. | ||
## [4.0.0] | ||
### Added | ||
- Add `ControllerGetStateAction` and `ControllerStateChangeEvent` types ([#1890](https://github.com/MetaMask/core/pull/1890), [#2029](https://github.com/MetaMask/core/pull/2029)) | ||
@@ -42,2 +52,3 @@ - Add `NamespacedName` type ([#1890](https://github.com/MetaMask/core/pull/1890)) | ||
### Changed | ||
- **BREAKING:** Alter controller messenger `ActionHandler` type so `Action` type parameter must satisfy (updated) `ActionConstraint` ([#1890](https://github.com/MetaMask/core/pull/1890)) | ||
@@ -61,16 +72,24 @@ - **BREAKING:** Alter controller messenger `ExtractActionParameters` utility type so `Action` type parameter must satisfy (updated) `ActionConstraint` ([#1890](https://github.com/MetaMask/core/pull/1890)) | ||
## [3.2.3] | ||
### Changed | ||
- Bump dependency on `@metamask/utils` to ^8.1.0 ([#1639](https://github.com/MetaMask/core/pull/1639)) | ||
## [3.2.2] | ||
### Changed | ||
- Update TypeScript to v4.8.x ([#1718](https://github.com/MetaMask/core/pull/1718)) | ||
## [3.2.1] | ||
### Changed | ||
- There are no consumer-facing changes to this package. This version is a part of a synchronized release across all packages in our monorepo. | ||
## [3.2.0] | ||
### Changed | ||
- When deriving state, skip properties with invalid metadata ([#1529](https://github.com/MetaMask/core/pull/1529)) | ||
- When deriving state, skip properties with invalid metadata ([#1529](https://github.com/MetaMask/core/pull/1529)) | ||
- The previous behavior was to throw an error | ||
@@ -81,3 +100,5 @@ - An error is thrown in a timeout handler so that it can still be captured in the console, and by global unhandled error handlers. | ||
## [3.1.0] | ||
### Changed | ||
- Prevent event publish from throwing error ([#1475](https://github.com/MetaMask/core/pull/1475)) | ||
@@ -88,3 +109,5 @@ - The controller messenger will no longer throw when an event subscriber throws an error. Calls to `publish` (either within controllers or on a messenger instance directly) will no longer throw errors. | ||
## [3.0.0] | ||
### Changed | ||
- **BREAKING:** Bump to Node 16 ([#1262](https://github.com/MetaMask/core/pull/1262)) | ||
@@ -94,3 +117,5 @@ - Replace `@metamask/controller-utils` dependency with `@metamask/utils` ([#1370](https://github.com/MetaMask/core/pull/1370)) | ||
## [2.0.0] | ||
### Removed | ||
- **BREAKING:** Remove `isomorphic-fetch` ([#1106](https://github.com/MetaMask/controllers/pull/1106)) | ||
@@ -100,15 +125,22 @@ - Consumers must now import `isomorphic-fetch` or another polyfill themselves if they are running in an environment without `fetch` | ||
## [1.1.2] | ||
### Changed | ||
- Rename this repository to `core` ([#1031](https://github.com/MetaMask/controllers/pull/1031)) | ||
- Update `@metamask/controller-utils` package ([#1041](https://github.com/MetaMask/controllers/pull/1041)) | ||
- Update `@metamask/controller-utils` package ([#1041](https://github.com/MetaMask/controllers/pull/1041)) | ||
## [1.1.1] | ||
### Changed | ||
- Relax dependency on `@metamask/controller-utils` (use `^` instead of `~`) ([#998](https://github.com/MetaMask/core/pull/998)) | ||
## [1.1.0] | ||
### Added | ||
- Add `applyPatches` function to BaseControllerV2 ([#980](https://github.com/MetaMask/core/pull/980)) | ||
### Changed | ||
- Action and event handler types are now exported ([#987](https://github.com/MetaMask/core/pull/987)) | ||
@@ -118,5 +150,9 @@ - Update `update` function to expose patches ([#980](https://github.com/MetaMask/core/pull/980)) | ||
## [1.0.0] | ||
### Added | ||
- Initial release | ||
- As a result of converting our shared controllers repo into a monorepo ([#831](https://github.com/MetaMask/core/pull/831)), we've created this package from select parts of [`@metamask/controllers` v33.0.0](https://github.com/MetaMask/core/tree/v33.0.0), namely: | ||
- `src/BaseController.ts` | ||
@@ -123,0 +159,0 @@ - `src/BaseController.test.ts` |
{ | ||
"name": "@metamask-previews/base-controller", | ||
"version": "4.1.1-preview.8cdddaf", | ||
"version": "4.1.1-preview.91dd28a", | ||
"description": "Provides scaffolding for controllers as well a communication system for all controllers", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
161355