Skip to content

Commit

Permalink
fix(netlify): ensure preview command is correct (#2561)
Browse files Browse the repository at this point in the history
  • Loading branch information
danielroe authored Jun 25, 2024
1 parent 169687b commit d16a47b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/presets/netlify/legacy/preset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -130,10 +130,11 @@ const netlifyStatic = defineNitroPreset(
{
extends: "static",
output: {
dir: "{{ rootDir }}/dist",
publicDir: "{{ rootDir }}/dist",
},
commands: {
preview: "npx serve ./static",
preview: "npx serve ./",
},
hooks: {
"rollup:before": (nitro: Nitro) => {
Expand Down
3 changes: 2 additions & 1 deletion src/presets/netlify/preset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,11 @@ const netlifyStatic = defineNitroPreset(
{
extends: "static",
output: {
dir: "{{ rootDir }}/dist",
publicDir: "{{ rootDir }}/dist",
},
commands: {
preview: "npx serve ./static",
preview: "npx serve ./",
},
hooks: {
async compiled(nitro: Nitro) {
Expand Down

0 comments on commit d16a47b

Please sign in to comment.