refactor: extract navbar and footer into reusable handlebars partials
- Replace duplicated navbar markup across all HTML pages with {{> navbar }} partial
- Replace duplicated footer markup across all HTML pages with {{> footer }} partial
- Add TypeScript type definitions for vite-plugin-handlebars integration
- Update vite.config.ts to support handlebars partial compilation
- Update tsconfig.json to include handlebars type definitions
- Update nginx.conf for proper static file serving with partials
- Update translation files for de, pt, tr, vi, and zh-TW locales
- Reduce code duplication and improve maintainability across 13+ HTML pages
- Ensure consistent navbar and footer behavior across the entire application
This commit is contained in:
@@ -26,16 +26,8 @@
|
||||
"compilerOptions": {
|
||||
"target": "ES2022",
|
||||
"module": "ESNext",
|
||||
"lib": [
|
||||
"ES2022",
|
||||
"DOM",
|
||||
"DOM.Iterable",
|
||||
"WebWorker"
|
||||
],
|
||||
"types": [
|
||||
"vite/client",
|
||||
"vitest/globals"
|
||||
], // Added vitest/globals
|
||||
"lib": ["ES2022", "DOM", "DOM.Iterable", "WebWorker"],
|
||||
"types": ["vite/client", "vitest/globals"], // Added vitest/globals
|
||||
/* Easier module handling for Vite */
|
||||
"moduleResolution": "bundler",
|
||||
"allowJs": true,
|
||||
@@ -59,21 +51,10 @@
|
||||
/* Path aliases (optional but helpful) */
|
||||
"baseUrl": ".",
|
||||
"paths": {
|
||||
"@/*": [
|
||||
"./src/*"
|
||||
],
|
||||
"@/types": [
|
||||
"./src/js/types/index.ts"
|
||||
]
|
||||
"@/*": ["./src/*"],
|
||||
"@/types": ["./src/js/types/index.ts"]
|
||||
}
|
||||
},
|
||||
"include": [
|
||||
"src",
|
||||
"src/**/*.ts",
|
||||
"public/workers"
|
||||
], // Updated to include all TS files
|
||||
"exclude": [
|
||||
"node_modules",
|
||||
"dist"
|
||||
]
|
||||
}
|
||||
"include": ["src", "src/**/*.ts", "public/workers", "vite.config.ts"], // Updated to include all TS files
|
||||
"exclude": ["node_modules", "dist"]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user