mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-11 08:33:53 +00:00
explicitly set outName in targets to avoid regression
This commit is contained in:
parent
35720380c2
commit
b258c2af2c
@ -17,6 +17,7 @@ if ('serviceWorker' in navigator) {
|
|||||||
return {
|
return {
|
||||||
entry: '{{ runtimeDir }}/targets/service-worker',
|
entry: '{{ runtimeDir }}/targets/service-worker',
|
||||||
targetDir: '{{ publicDir }}',
|
targetDir: '{{ publicDir }}',
|
||||||
|
outName: '_nuxt.js',
|
||||||
nuxtHooks: {
|
nuxtHooks: {
|
||||||
'vue-renderer:ssr:templateParams' (params) {
|
'vue-renderer:ssr:templateParams' (params) {
|
||||||
params.APP += script
|
params.APP += script
|
||||||
|
@ -6,6 +6,7 @@ import { worker } from './worker'
|
|||||||
|
|
||||||
export const cloudflare: SLSTarget = extendTarget(worker, {
|
export const cloudflare: SLSTarget = extendTarget(worker, {
|
||||||
entry: '{{ runtimeDir }}/targets/cloudflare',
|
entry: '{{ runtimeDir }}/targets/cloudflare',
|
||||||
|
outName: '_nuxt.js',
|
||||||
generateIgnore: [
|
generateIgnore: [
|
||||||
'wrangler.toml'
|
'wrangler.toml'
|
||||||
],
|
],
|
||||||
|
@ -5,6 +5,7 @@ import { SLSTarget } from '../config'
|
|||||||
|
|
||||||
export const lambda: SLSTarget = {
|
export const lambda: SLSTarget = {
|
||||||
entry: '{{ runtimeDir }}/targets/lambda',
|
entry: '{{ runtimeDir }}/targets/lambda',
|
||||||
|
outName: '_nuxt.js',
|
||||||
hooks: {
|
hooks: {
|
||||||
'done' ({ rollupConfig }) {
|
'done' ({ rollupConfig }) {
|
||||||
const entry = relative(process.cwd(), rollupConfig.output.file).replace(/\.js$/, '')
|
const entry = relative(process.cwd(), rollupConfig.output.file).replace(/\.js$/, '')
|
||||||
|
@ -3,6 +3,7 @@ import { SLSTarget } from '../config'
|
|||||||
import { lambda } from './lambda'
|
import { lambda } from './lambda'
|
||||||
|
|
||||||
export const netlify: SLSTarget = extendTarget(lambda, {
|
export const netlify: SLSTarget = extendTarget(lambda, {
|
||||||
|
outName: '_nuxt.js',
|
||||||
generateIgnore: [
|
generateIgnore: [
|
||||||
'netlify.toml',
|
'netlify.toml',
|
||||||
'_redirects'
|
'_redirects'
|
||||||
|
@ -4,9 +4,12 @@ import { SLSTarget } from '../config'
|
|||||||
|
|
||||||
export const node: SLSTarget = {
|
export const node: SLSTarget = {
|
||||||
entry: '{{ runtimeDir }}/targets/node',
|
entry: '{{ runtimeDir }}/targets/node',
|
||||||
|
outName: 'index.js',
|
||||||
hooks: {
|
hooks: {
|
||||||
'done' ({ rollupConfig }) {
|
'done' ({ rollupConfig }) {
|
||||||
const entry = relative(process.cwd(), rollupConfig.output.file).replace(/\.js$/, '')
|
const entry = relative(process.cwd(), rollupConfig.output.file)
|
||||||
|
.replace(/\.js$/, '')
|
||||||
|
.replace(/\/index$/, '')
|
||||||
consola.info(`Ready to deploy node entrypoint: \`${entry}\``)
|
consola.info(`Ready to deploy node entrypoint: \`${entry}\``)
|
||||||
consola.info(`You can try using \`node ${entry} [path]\``)
|
consola.info(`You can try using \`node ${entry} [path]\``)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user