diff --git a/package-lock.json b/package-lock.json index 7bea344..d5cabb5 100644 --- a/package-lock.json +++ b/package-lock.json @@ -30,7 +30,6 @@ "class-validator": "^0.14.1", "cookie-parser": "^1.4.7", "ejs": "^6.0.1", - "express-ejs-layouts": "^2.5.1", "helmet": "^8.0.0", "ioredis": "^5.5.0", "nestjs-pino": "^4.1.0", @@ -6473,11 +6472,6 @@ "url": "https://opencollective.com/express" } }, - "node_modules/express-ejs-layouts": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/express-ejs-layouts/-/express-ejs-layouts-2.5.1.tgz", - "integrity": "sha512-IXROv9n3xKga7FowT06n1Qn927JR8ZWDn5Dc9CJQoiiaaDqbhW5PDmWShzbpAa2wjWT1vJqaIM1S6vJwwX11gA==" - }, "node_modules/express/node_modules/cookie-signature": { "version": "1.2.2", "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.2.2.tgz", diff --git a/package.json b/package.json index 0f890d4..e5f98ce 100644 --- a/package.json +++ b/package.json @@ -45,7 +45,6 @@ "class-validator": "^0.14.1", "cookie-parser": "^1.4.7", "ejs": "^6.0.1", - "express-ejs-layouts": "^2.5.1", "helmet": "^8.0.0", "ioredis": "^5.5.0", "nestjs-pino": "^4.1.0", diff --git a/src/main.ts b/src/main.ts index 5822c44..c14edb4 100644 --- a/src/main.ts +++ b/src/main.ts @@ -4,7 +4,6 @@ import { Logger } from 'nestjs-pino'; import { NestExpressApplication } from '@nestjs/platform-express'; import * as helmet from 'helmet'; import cookieParser from 'cookie-parser'; -import expressLayouts from 'express-ejs-layouts'; import { join } from 'node:path'; import { existsSync } from 'node:fs'; import { AppModule } from './app.module'; @@ -42,8 +41,6 @@ async function bootstrap(): Promise { if (existsSync(viewsPath)) { app.setBaseViewsDir(viewsPath); app.setViewEngine('ejs'); - app.use(expressLayouts); - app.set('layout', 'layouts/main'); } const publicPath = join(process.cwd(), 'public'); diff --git a/views/admin/clients.ejs b/views/admin/clients.ejs index 3b31b2a..1a68c50 100644 --- a/views/admin/clients.ejs +++ b/views/admin/clients.ejs @@ -1,3 +1,4 @@ +<%- include('../partials/header') %>