From 7ca57b0f625997130574584e1526cec265af5986 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 10 Oct 2023 07:09:06 +0000 Subject: [PATCH] Version Packages --- .changeset/chilly-monkeys-add.md | 5 --- .changeset/giant-papayas-hear.md | 17 --------- .changeset/gold-spies-battle.md | 34 ------------------ .changeset/quiet-sloths-care.md | 5 --- packages/react-fast-hoc/CHANGELOG.md | 52 ++++++++++++++++++++++++++++ packages/react-fast-hoc/package.json | 2 +- 6 files changed, 53 insertions(+), 62 deletions(-) delete mode 100644 .changeset/chilly-monkeys-add.md delete mode 100644 .changeset/giant-papayas-hear.md delete mode 100644 .changeset/gold-spies-battle.md delete mode 100644 .changeset/quiet-sloths-care.md diff --git a/.changeset/chilly-monkeys-add.md b/.changeset/chilly-monkeys-add.md deleted file mode 100644 index 1ca482d..0000000 --- a/.changeset/chilly-monkeys-add.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"react-fast-hoc": minor ---- - -Deprecated `mimicToNewComponent` and make default to false (true was before) diff --git a/.changeset/giant-papayas-hear.md b/.changeset/giant-papayas-hear.md deleted file mode 100644 index ff43585..0000000 --- a/.changeset/giant-papayas-hear.md +++ /dev/null @@ -1,17 +0,0 @@ ---- -"react-fast-hoc": minor ---- - -Made displayName editable for each transformed component: - -```tsx -const _ = transformProps(A, (props) => props, { - displayNameTransform: { - value: (name) => name + "C", - type: "rewrite-dynamic", - }, -}); -expect(_.displayName).toBe("AC"); -_.displayName = "D"; -expect(_.displayName).toBe("D"); -``` diff --git a/.changeset/gold-spies-battle.md b/.changeset/gold-spies-battle.md deleted file mode 100644 index 1c9681a..0000000 --- a/.changeset/gold-spies-battle.md +++ /dev/null @@ -1,34 +0,0 @@ ---- -"react-fast-hoc": minor ---- - -Added new syntax for name rewriting, old one is deprecated and will be removed soon - -Static name rewrite - -```tsx -transformProps(B, (props) => props, { - displayNameTransform: { - type: "rewrite", - value: "D", - }, -}); - -transformProps(A, (props) => props, { - displayNameTransform: { - type: "prefix", - value: "CBC", - }, -}); -``` - -Dynamic name rewrite - -```tsx -transformProps(A, (props) => props, { - displayNameTransform: { - value: (name) => name + "C", - type: "rewrite-dynamic", - }, -}); -``` diff --git a/.changeset/quiet-sloths-care.md b/.changeset/quiet-sloths-care.md deleted file mode 100644 index 1f8e806..0000000 --- a/.changeset/quiet-sloths-care.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"react-fast-hoc": minor ---- - -Added support for components wrapped with `React.lazy` diff --git a/packages/react-fast-hoc/CHANGELOG.md b/packages/react-fast-hoc/CHANGELOG.md index 4cb552b..0bf87a5 100644 --- a/packages/react-fast-hoc/CHANGELOG.md +++ b/packages/react-fast-hoc/CHANGELOG.md @@ -1,5 +1,57 @@ # react-fast-hoc +## 0.3.0 + +### Minor Changes + +- d2cc312: Deprecated `mimicToNewComponent` and make default to false (true was before) +- 8680658: Made displayName editable for each transformed component: + + ```tsx + const _ = transformProps(A, (props) => props, { + displayNameTransform: { + value: (name) => name + "C", + type: "rewrite-dynamic", + }, + }); + expect(_.displayName).toBe("AC"); + _.displayName = "D"; + expect(_.displayName).toBe("D"); + ``` + +- d2cc312: Added new syntax for name rewriting, old one is deprecated and will be removed soon + + Static name rewrite + + ```tsx + transformProps(B, (props) => props, { + displayNameTransform: { + type: "rewrite", + value: "D", + }, + }); + + transformProps(A, (props) => props, { + displayNameTransform: { + type: "prefix", + value: "CBC", + }, + }); + ``` + + Dynamic name rewrite + + ```tsx + transformProps(A, (props) => props, { + displayNameTransform: { + value: (name) => name + "C", + type: "rewrite-dynamic", + }, + }); + ``` + +- f057209: Added support for components wrapped with `React.lazy` + ## 0.2.1 ### Patch Changes diff --git a/packages/react-fast-hoc/package.json b/packages/react-fast-hoc/package.json index 3f161bb..e819f1d 100644 --- a/packages/react-fast-hoc/package.json +++ b/packages/react-fast-hoc/package.json @@ -1,7 +1,7 @@ { "name": "react-fast-hoc", "license": "MIT", - "version": "0.2.1", + "version": "0.3.0", "sideEffects": false, "type": "module", "publishConfig": {