Skip to content

Commit

Permalink
fix(preact): use updateConfig hook (#3166)
Browse files Browse the repository at this point in the history
  • Loading branch information
natemoo-re authored Apr 21, 2022
1 parent f73d33c commit 70263cf
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
5 changes: 5 additions & 0 deletions .changeset/thick-beds-flow.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@astrojs/preact': patch
---

Fix integration to use updateConfig rather than returning a partial config object
6 changes: 3 additions & 3 deletions packages/integrations/preact/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,11 @@ export default function (): AstroIntegration {
return {
name: '@astrojs/preact',
hooks: {
'astro:config:setup': ({ addRenderer }) => {
'astro:config:setup': ({ addRenderer, updateConfig }) => {
addRenderer(getRenderer());
return {
updateConfig({
vite: getViteConfiguration(),
};
})
},
},
};
Expand Down

0 comments on commit 70263cf

Please sign in to comment.