Skip to content

Commit

Permalink
fix(partytown): allow overriding the lib option (close #8760) (#8892)
Browse files Browse the repository at this point in the history
Co-authored-by: Sarah Rainsberger <[email protected]>
  • Loading branch information
2 people authored and natemoo-re committed Nov 22, 2023
1 parent 26a3f34 commit 6b42dac
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/forty-eggs-raise.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@astrojs/partytown': patch
---

Adds the ability to override the `lib` option in `astro.config.mjs`
2 changes: 1 addition & 1 deletion packages/integrations/partytown/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ export default function createPlugin(options?: PartytownOptions): AstroIntegrati
'astro:config:setup': ({ config: _config, command, injectScript }) => {
const lib = `${appendForwardSlash(_config.base)}~partytown/`;
const partytownConfig = {
...options?.config,
lib,
...options?.config,
debug: options?.config?.debug ?? command === 'dev',
};
partytownSnippetHtml = partytownSnippet(partytownConfig);
Expand Down

0 comments on commit 6b42dac

Please sign in to comment.