From 99848d18524e7dafba13ee7811e6a0e4ce552c54 Mon Sep 17 00:00:00 2001 From: Dmytro Stanchiev Date: Thu, 18 Sep 2025 11:33:06 -0400 Subject: [PATCH] build: configure absolute imports using `@` alias Configures TypeScript path aliases for cleaner and more maintainable imports. --- src/index.ts | 2 +- tsconfig.json | 10 ++++++++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/index.ts b/src/index.ts index 87bf95e..f25df7b 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,4 +1,4 @@ -import fetchKijijiItems from "./kijiji"; +import fetchKijijiItems from "@/kijiji"; const PORT = process.env.PORT || 4005; diff --git a/tsconfig.json b/tsconfig.json index 0a3d022..2aeb3d1 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -24,6 +24,12 @@ // Some stricter flags (disabled by default) "noUnusedLocals": false, "noUnusedParameters": false, - "noPropertyAccessFromIndexSignature": false - } + "noPropertyAccessFromIndexSignature": false, + + "paths": { + "@/*": ["./src/*"] + } + }, + "include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"], + "exclude": ["node_modules"] }