mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-29 00:52:01 +00:00
fix(nuxt,schema): remove .js
extension from template imports
This commit is contained in:
parent
94a6f05812
commit
0d4a622f3a
@ -17,7 +17,7 @@ import type { Nuxt, NuxtOptions, RuntimeConfig } from 'nuxt/schema'
|
|||||||
import { version as nuxtVersion } from '../../package.json'
|
import { version as nuxtVersion } from '../../package.json'
|
||||||
import { distDir } from '../dirs'
|
import { distDir } from '../dirs'
|
||||||
import { toArray } from '../utils'
|
import { toArray } from '../utils'
|
||||||
import { template as defaultSpaLoadingTemplate } from './templates/spa-loading-icon.js'
|
import { template as defaultSpaLoadingTemplate } from './templates/spa-loading-icon'
|
||||||
import { ImportProtectionPlugin, nuxtImportProtections } from './plugins/import-protection'
|
import { ImportProtectionPlugin, nuxtImportProtections } from './plugins/import-protection'
|
||||||
|
|
||||||
const logLevelMapReverse = {
|
const logLevelMapReverse = {
|
||||||
|
@ -66,7 +66,7 @@ export default <NitroErrorHandler> async function errorhandler (error: H3Error,
|
|||||||
|
|
||||||
// Fallback to static rendered error page
|
// Fallback to static rendered error page
|
||||||
if (!res) {
|
if (!res) {
|
||||||
const { template } = import.meta.dev ? await import('./error-dev.js') : await import('./error-500.js')
|
const { template } = import.meta.dev ? await import('./error-dev') : await import('./error-500')
|
||||||
if (import.meta.dev) {
|
if (import.meta.dev) {
|
||||||
// TODO: Support `message` in template
|
// TODO: Support `message` in template
|
||||||
(errorObject as any).description = errorObject.message
|
(errorObject as any).description = errorObject.message
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import { defineUntypedSchema } from 'untyped'
|
import { defineUntypedSchema } from 'untyped'
|
||||||
import { template as loadingTemplate } from '../templates/loading.js'
|
import { template as loadingTemplate } from '../templates/loading'
|
||||||
|
|
||||||
export default defineUntypedSchema({
|
export default defineUntypedSchema({
|
||||||
devServer: {
|
devServer: {
|
||||||
|
Loading…
Reference in New Issue
Block a user