Mi Portfolio follows SvelteKit’s conventional file-based layout. The entire application is served from a single route underDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/lgomegarc/mi-portfolio/llms.txt
Use this file to discover all available pages before exploring further.
src/routes/, while all reusable UI building blocks live under src/lib/components/. This separation keeps page-level orchestration cleanly distinct from component logic, and SvelteKit’s $lib alias makes importing those components frictionless from anywhere in the project.
Directory Overview
Routing
SvelteKit uses a file-based routing system: each file insidesrc/routes/ that follows the +page.svelte naming convention becomes a URL route. Mi Portfolio uses a single route:
src/routes/+page.svelte— The home page. It renders the Hero section inline and importsAboutSection,ProjectsSection, andContactSectionas components, each wrapped in a<section>tag with an anchorid.src/routes/+layout.svelte— The root layout that wraps every page. It imports and renders<Navbar />above the<slot />and<Footer />below it.
#home, #about, #projects, #contact — are the targets for every link in the Navbar, enabling smooth-scroll navigation within the single page without any client-side routing changes.
The $lib Alias
SvelteKit automatically creates a$lib path alias that points to src/lib/. This means you can import any file from the lib/ directory using the $lib prefix, regardless of how deeply nested the importing file is — no ../../../ chains needed.
All seven components in src/lib/components/ are imported this way:
SvelteKit’s
$lib alias means you never need relative import paths for components — use $lib/components/X.svelte from anywhere in src/.Static Assets
Files placed in thestatic/ folder are served directly from the root URL at build time. SvelteKit copies them verbatim to the output directory, so /Profile_Image.jpg in static/ is accessible at https://your-domain/Profile_Image.jpg.
The following assets are used by the portfolio:
| File | Used By | Purpose |
|---|---|---|
Profile_Image.jpg | AboutSection.svelte | Profile photo displayed in the About section |
Portfolio.png | ProjectsSection.svelte | Screenshot for the Portfolio project card |
Jira.png | ProjectsSection.svelte | Screenshot for the Soporte E-commerce project card |
codigo.png | ProjectsSection.svelte | Screenshot for the Mic-Prices project card |
CV Leila.pdf | SocialLinks.svelte | Downloadable CV, triggered by the CV icon link |
robots.txt | Served automatically | Search engine crawl instructions |
Configuration Files
-
svelte.config.js— The main SvelteKit configuration. Uses@sveltejs/adapter-vercelfor zero-config Vercel deployment andsvelte-preprocesswith{ typescript: { transpileOnly: true } }to enable TypeScript support inside.sveltefiles. -
tailwind.config.cjs— Tailwind CSS configuration. Setscontentpaths to scan all.html,.js,.ts, and.sveltefiles undersrc/. Extends the default theme with two custom colors:primary(#5a5edc) andsecondary-bg(#f0f0f5). -
vite.config.ts— Vite bundler configuration. Registers the@sveltejs/kit/viteplugin, which integrates SvelteKit’s routing and SSR capabilities into the Vite dev server and build pipeline. -
tsconfig.json— TypeScript compiler options. Extends SvelteKit’s recommended base config and sets up path aliases consistent with the SvelteKit runtime. -
postcss.config.cjs— PostCSS configuration. Registerstailwindcssandautoprefixeras plugins, which Vite invokes during CSS processing to generate and vendor-prefix the final Tailwind stylesheet.