You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: packages/plugin-react/CHANGELOG.md
+11Lines changed: 11 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,6 +2,17 @@
2
2
3
3
## Unreleased
4
4
5
+
### Add support for compound components ([#518](https://github.com/vitejs/vite-plugin-react/pull/518))
6
+
7
+
HMR now works for compound components like this:
8
+
9
+
```tsx
10
+
const Root = () => <div>Accordion Root</div>
11
+
const Item = () => <div>Accordion Item</div>
12
+
13
+
exportconst Accordion = { Root, Item }
14
+
```
15
+
5
16
### Return `Plugin[]` instead of `PluginOption[]`
6
17
7
18
The return type has changed from `react(): PluginOption[]` to more specialized type `react(): Plugin[]`. This allows for type-safe manipulation of plugins, for example:
0 commit comments