Skip to content

Commit

Permalink
Use alias and absolute path for importing other code/assets
Browse files Browse the repository at this point in the history
  • Loading branch information
sukso96100 committed Jan 14, 2024
1 parent 4e6b0f5 commit 1560e06
Show file tree
Hide file tree
Showing 14 changed files with 21 additions and 16 deletions.
File renamed without changes
File renamed without changes
File renamed without changes
2 changes: 1 addition & 1 deletion src/config.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import UbuntuIndiaLogo from "./UbuntuIndia.svg"
import UbuntuIndiaLogo from "@assets/UbuntuIndia.svg"

export const config = {
siteTitle: "UbuCon Asia 2024",
Expand Down
3 changes: 1 addition & 2 deletions src/layouts/MarkdownLayout.astro
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
import "vanilla-framework/_index.scss";
import GlobalNavigation from "../components/GlobalNavigation";
import Shell from "./Shell.astro";
import Shell from "@layouts/Shell.astro";
import { Strip, Col, Row } from "@canonical/react-components";
import type { MarkdownLayoutProps } from 'astro';
Expand Down
4 changes: 2 additions & 2 deletions src/layouts/Shell.astro
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
import "vanilla-framework/_index.scss";
import GlobalNavigation from "../components/GlobalNavigation.tsx";
import Layout from "./Layout.astro";
import GlobalNavigation from "@components/GlobalNavigation.tsx";
import Layout from "@layouts/Layout.astro";
interface Props {
title: string;
Expand Down
2 changes: 1 addition & 1 deletion src/pages/about.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
layout: ../layouts/MarkdownLayout.astro
layout: /src/layouts/MarkdownLayout.astro
title: About UbuCon Asia 2024
description: Brief introduction to UbuCon Asia 2024
---
Expand Down
8 changes: 4 additions & 4 deletions src/pages/index.astro
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
---
import Shell from "../layouts/Shell.astro";
import BlogFeed from "../components/BlogFeed.astro";
import Shell from "@layouts/Shell.astro";
import BlogFeed from "@components/BlogFeed.astro";
import { config } from "../config";
import { Strip, Col, Row } from "@canonical/react-components";
import uca24logo from "./logo.svg";
import logoPlaceHolder from "./logo_placeholder.svg";
import uca24logo from "@assets/logo.svg";
import logoPlaceHolder from "@assets/logo_placeholder.svg";
---

<Shell title={config.siteTitle}>
Expand Down
2 changes: 1 addition & 1 deletion src/pages/venue-and-travel/accommodations.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
layout: ../../layouts/MarkdownLayout.astro
layout: /src/layouts/MarkdownLayout.astro
title: Accommodations
description: Find accomodations nearby from our curated list
---
Expand Down
2 changes: 1 addition & 1 deletion src/pages/venue-and-travel/explore-city.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
layout: ../../layouts/MarkdownLayout.astro
layout: /src/layouts/MarkdownLayout.astro
title: Exploring the city
description: What to do and Where to go in Jaipur?
---
Expand Down
2 changes: 1 addition & 1 deletion src/pages/venue-and-travel/getting-to-city.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
layout: ../../layouts/MarkdownLayout.astro
layout: /src/layouts/MarkdownLayout.astro
title: Getting to the city
description: Things to know and prepare before travelling to Jaipur, India
---
Expand Down
2 changes: 1 addition & 1 deletion src/pages/venue-and-travel/travel-grant.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
layout: ../../layouts/MarkdownLayout.astro
layout: /src/layouts/MarkdownLayout.astro
title: Travel grant
description: Details on travel grant program for those who need travel funding support
---
Expand Down
2 changes: 1 addition & 1 deletion src/pages/venue-and-travel/venue-and-safety.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
layout: ../../layouts/MarkdownLayout.astro
layout: /src/layouts/MarkdownLayout.astro
title: Venue & Safety
description: Detailed Venue, Health & Safety information
---
Expand Down
8 changes: 7 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@
"extends": "astro/tsconfigs/strict",
"compilerOptions": {
"jsx": "react-jsx",
"jsxImportSource": "react"
"jsxImportSource": "react",
"baseUrl": ".",
"paths": {
"@components/*": ["src/components/*"],
"@layouts/*": ["src/layouts/*"],
"@assets/*": ["src/assets/*"]
}
}
}

0 comments on commit 1560e06

Please sign in to comment.