Skip to content

Commit 008e48d

Browse files
committed
fix: linting errors
1 parent d5679ae commit 008e48d

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

eslint.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ export default [
5656
rules: {
5757
'@typescript-eslint/no-unused-expressions': ['error', { allowShortCircuit: true }],
5858
'@typescript-eslint/no-empty-object-type': ['error', { allowInterfaces: 'always' }],
59+
'@typescript-eslint/no-unnecessary-type-assertion': ['warn', {}],
5960
'@typescript-eslint/no-unused-vars': [
6061
'error',
6162
{

src/pages.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ export const i18nPathToPath = ${JSON.stringify(routeResources.i18nPathToPath, nu
7575

7676
// analyze layer pages
7777
for (const layer of nuxt.options._layers) {
78-
const pagesDir = resolve(projectLayer.config.rootDir, layer.config.srcDir, layer.config.dir?.pages ?? 'pages')
78+
const pagesDir = resolve(projectLayer!.config.rootDir, layer.config.srcDir, layer.config.dir?.pages ?? 'pages')
7979
analyzeNuxtPages(ctx, pagesDir, pages)
8080
}
8181

@@ -276,7 +276,7 @@ export function getRouteOptionsResolver(
276276
const res = getRouteOptions(route, localeCodes, ctx, defaultLocale, customRoutes)
277277
if (route.file) {
278278
const localeCfg = res?.srcPaths
279-
const mappedPath = ctx.fileToPath[route.file]
279+
const mappedPath = ctx.fileToPath[route.file]!
280280
ctx.pathToConfig[mappedPath] ??= {} as Record<string, string | boolean>
281281

282282
// set paths for all locales, assume no custom path is a disabled locale

0 commit comments

Comments
 (0)