Skip to content

Commit

Permalink
fix: Use directory name when zip.name and package.json#name are n…
Browse files Browse the repository at this point in the history
…ot provided
  • Loading branch information
aklinker1 committed Oct 3, 2024
1 parent d270250 commit c668582
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/wxt/src/core/zip.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ export async function zip(config?: InlineConfig): Promise<string[]> {

const projectName =
wxt.config.zip.name ??
safeFilename((await getPackageJson())?.name || path.dirname(process.cwd()));
safeFilename(
(await getPackageJson())?.name || path.basename(process.cwd()),
);
const applyTemplate = (template: string): string =>
template
.replaceAll('{{name}}', projectName)
Expand Down

0 comments on commit c668582

Please sign in to comment.