Skip to content

Commit c49b66f

Browse files
authored
Merge pull request #64 from devwqc/feat/prettier-tailwind
[feat] prettier tailwind
2 parents 76f1714 + cc80ba3 commit c49b66f

File tree

10 files changed

+83
-18
lines changed

10 files changed

+83
-18
lines changed

.prettierrc.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export default {
66
singleQuote: true,
77
tabWidth: 2,
88
trailingComma: 'es5',
9-
plugins: ['prettier-plugin-astro'],
9+
plugins: ['prettier-plugin-astro', 'prettier-plugin-tailwindcss'],
1010
overrides: [
1111
{
1212
files: '*.astro',

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
"devDependencies": {
4444
"@tailwindcss/typography": "0.5.15",
4545
"prettier": "3.3.3",
46-
"prettier-plugin-astro": "0.14.1"
46+
"prettier-plugin-astro": "0.14.1",
47+
"prettier-plugin-tailwindcss": "0.6.8"
4748
}
4849
}

pnpm-lock.yaml

Lines changed: 64 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/components/NavigationMobile.astro

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import HamburgerSvg from './HamburgerSvg.astro';
1818
</li>
1919
))
2020
}
21-
<button id="closeMenuBtn" type="button" class="absolute top-10 right-5">
21+
<button id="closeMenuBtn" type="button" class="absolute right-5 top-10">
2222
<CloseSvg class="size-7" />
2323
</button>
2424
</ul>
@@ -35,6 +35,6 @@ import HamburgerSvg from './HamburgerSvg.astro';
3535

3636
<style>
3737
.expanded {
38-
@apply bg-white fixed inset-0 flex flex-col gap-5;
38+
@apply fixed inset-0 flex flex-col gap-5 bg-white;
3939
}
4040
</style>

src/components/Tech.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,6 @@ const { label } = Astro.props;
77
---
88

99
<span
10-
class="inline-flex justify-center items-center border rounded-full bg-gray-100 text-emerald-600 px-2 py-1"
10+
class="inline-flex items-center justify-center rounded-full border bg-gray-100 px-2 py-1 text-emerald-600"
1111
>{label}</span
1212
>

src/layouts/PageLayout.astro

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@ const { title, description } = Astro.props;
2222
<meta name="description" content={description} />
2323
<slot name="head" />
2424
</head>
25-
<body class="max-w-[48rem] mx-auto my-0 px-5">
26-
<div class="min-h-screen flex flex-col justify-between">
25+
<body class="mx-auto my-0 max-w-[48rem] px-5">
26+
<div class="flex min-h-screen flex-col justify-between">
2727
<div>
2828
<Header />
2929
<slot />

src/pages/about.astro

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ import PageLayout from '@/layouts/PageLayout.astro';
66
<PageLayout title="About">
77
<article class="flex flex-col gap-10">
88
<header>
9-
<h1 class="text-3xl font-bold py-3">정봉찬</h1>
9+
<h1 class="py-3 text-3xl font-bold">정봉찬</h1>
1010
<p class="text-xl">프론트엔드 개발자</p>
1111
</header>
1212
<section>
13-
<h2 class="text-2xl font-bold py-2">경력</h2>
13+
<h2 class="py-2 text-2xl font-bold">경력</h2>
1414
<ul>
1515
<li>
1616
<p class="text-xl font-bold">메멘토에이아이</p>
@@ -26,7 +26,7 @@ import PageLayout from '@/layouts/PageLayout.astro';
2626
피부과 시술 예약 및 뷰티 컨설팅 시스템
2727
</p>
2828
<ul
29-
class="[&>:not(:first-child)]:before:content-['-'] [&>:not(:first-child)]:before:px-2"
29+
class="[&>:not(:first-child)]:before:px-2 [&>:not(:first-child)]:before:content-['-']"
3030
>
3131
<li class="py-2">
3232
<TechList
@@ -49,7 +49,7 @@ import PageLayout from '@/layouts/PageLayout.astro';
4949
피부과 관리 시스템, 백 오피스 시스템
5050
</p>
5151
<ul
52-
class="[&>:not(:first-child)]:before:content-['-'] [&>:not(:first-child)]:before:px-2"
52+
class="[&>:not(:first-child)]:before:px-2 [&>:not(:first-child)]:before:content-['-']"
5353
>
5454
<li class="py-2">
5555
<TechList
@@ -73,7 +73,7 @@ import PageLayout from '@/layouts/PageLayout.astro';
7373
<div class="py-2">
7474
<p class="text-lg font-bold">제품 발주 시스템</p>
7575
<ul
76-
class="[&>:not(:first-child)]:before:content-['-'] [&>:not(:first-child)]:before:px-2"
76+
class="[&>:not(:first-child)]:before:px-2 [&>:not(:first-child)]:before:content-['-']"
7777
>
7878
<li class="py-2">
7979
<TechList
@@ -100,7 +100,7 @@ import PageLayout from '@/layouts/PageLayout.astro';
100100
</ul>
101101
</section>
102102
<section>
103-
<h2 class="text-2xl font-bold py-2">교육</h2>
103+
<h2 class="py-2 text-2xl font-bold">교육</h2>
104104
<ul>
105105
<li>
106106
<p>

src/pages/blog/[...slug].astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ const { Content } = await post.render();
2222

2323
<PageLayout title={post.data.title}>
2424
<article>
25-
<header class="border-b pb-10 text-center flex flex-col gap-3">
25+
<header class="flex flex-col gap-3 border-b pb-10 text-center">
2626
<h1 class="text-4xl font-bold">{post.data.title}</h1>
2727
<p class="text-gray-500">
2828
<span>

src/pages/blog/index.astro

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ const posts = (await getCollection('blog')).sort(
1616
<article>
1717
<a
1818
href={`/blog/${post.slug}/`}
19-
class="hover:text-emerald-600 flex flex-col gap-1"
19+
class="flex flex-col gap-1 hover:text-emerald-600"
2020
>
2121
<h2 class="text-3xl font-bold">{post.data.title}</h2>
22-
<p class="text-gray-500 text-sm">
22+
<p class="text-sm text-gray-500">
2323
<span>
2424
작성일:
2525
<FormattedDate datetime={post.data.pubDate} />

src/pages/index.astro

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ const posts = (await getCollection('blog')).sort(
1616
<article>
1717
<a
1818
href={`/blog/${post.slug}/`}
19-
class="hover:text-emerald-600 flex flex-col gap-1"
19+
class="flex flex-col gap-1 hover:text-emerald-600"
2020
>
2121
<h2 class="text-3xl font-bold">{post.data.title}</h2>
22-
<p class="text-gray-500 text-sm">
22+
<p class="text-sm text-gray-500">
2323
<span>
2424
작성일:
2525
<FormattedDate datetime={post.data.pubDate} />

0 commit comments

Comments
 (0)