Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion packages/wxt/src/core/zip.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,9 @@ export async function zip(config?: InlineConfig): Promise<string[]> {
template
.replaceAll('{{name}}', projectName)
.replaceAll('{{browser}}', wxt.config.browser)
.replaceAll('{{version}}', output.manifest.version)
.replaceAll(
'{{version}}',
'{{versionName}}',
output.manifest.version_name ?? output.manifest.version,
)
.replaceAll('{{packageVersion}}', packageJson?.version)
Expand Down
6 changes: 4 additions & 2 deletions packages/wxt/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,8 @@ export interface InlineConfig {
* Available template variables:
*
* - <span v-pre>`{{name}}`</span> - The project's name converted to kebab-case
* - <span v-pre>`{{version}}`</span> - The version_name or version from the manifest
* - <span v-pre>`{{version}}`</span> - The version from the manifest
* - <span v-pre>`{{versionName}}`</span> - The version_name from the manifest or, if not set (i.e. if built for Firefox), the version from the manifest
* - <span v-pre>`{{packageVersion}}`</span> - The version from the package.json
* - <span v-pre>`{{browser}}`</span> - The target browser from the `--browser` CLI flag
* - <span v-pre>`{{mode}}`</span> - The current mode
Expand All @@ -171,7 +172,8 @@ export interface InlineConfig {
* Available template variables:
*
* - <span v-pre>`{{name}}`</span> - The project's name converted to kebab-case
* - <span v-pre>`{{version}}`</span> - The version_name or version from the manifest
* - <span v-pre>`{{version}}`</span> - The version from the manifest
* - <span v-pre>`{{versionName}}`</span> - The version_name from the manifest or, if not set (i.e. if built for Firefox), the version from the manifest
* - <span v-pre>`{{packageVersion}}`</span> - The version from the package.json
* - <span v-pre>`{{browser}}`</span> - The target browser from the `--browser` CLI flag
* - <span v-pre>`{{mode}}`</span> - The current mode
Expand Down
Loading