Changed project structure

This commit is contained in:
r-freeman 2023-01-19 21:53:37 +00:00
parent 25c41021cb
commit 753cc69abf
40 changed files with 13 additions and 13 deletions

View File

@ -4,7 +4,7 @@ import {usePathname} from 'next/navigation'
import {Container} from './Container'
import {formatDate} from '@/lib/formatDate'
import {Prose} from './Prose'
import {Views} from '@/components/Views'
import {Views} from './Views'
type ArticleLayout = {
children?: ReactNode

View File

@ -6,7 +6,7 @@ import {Popover, Transition} from '@headlessui/react'
import clsx from 'clsx'
import {Container} from './Container'
import avatar from '@/images/avatar.jpg'
import avatar from '@/public/static/images/avatar.jpg'
import type {Props} from 'types'

View File

@ -3,7 +3,7 @@
"baseUrl": ".",
"paths": {
"@/*": [
"src/*"
"*"
]
}
}

View File

@ -3,7 +3,7 @@ import * as path from 'path'
async function importArticle(articleFilename: string) {
let {meta, default: component} = await import(
`../pages/writing/${articleFilename}`
`/pages/writing/${articleFilename}`
)
return {
slug: articleFilename.replace(/(\/index)?\.mdx$/, ''),
@ -14,7 +14,7 @@ async function importArticle(articleFilename: string) {
export async function getAllArticles() {
let articleFilenames = await glob(['*.mdx', '*/index.mdx'], {
cwd: path.join(process.cwd(), 'src/pages/writing'),
cwd: path.join(process.cwd(), './pages/writing'),
})
let articles = await Promise.all(articleFilenames.map(importArticle))

View File

@ -3,7 +3,7 @@ import type {AppProps} from 'next/app'
import {Header} from '@/components/Header'
import {Footer} from '@/components/Footer'
import '../../styles/tailwind.css'
import '../styles/tailwind.css'
import 'focus-visible'
function usePrevious(value: string): string | null {

View File

@ -11,8 +11,8 @@ import {
TwitterIcon
} from '@/components/SocialIcons'
import {Props} from 'types'
import photoOfMeLg from '@/images/photo-of-me-lg.jpg'
import awsCCPBadge from '@/images/aws-certified-cloud-practitioner-badge.png'
import photoOfMe from '@/public/static/images/photo-of-me.jpg'
import awsCCPBadge from '@/public/static/images/aws-certified-cloud-practitioner-badge.png'
function SocialLink({
className,
@ -73,7 +73,7 @@ export default function About() {
<div className="lg:pl-20">
<div className="max-w-xs px-2.5 lg:max-w-none">
<Image
src={photoOfMeLg}
src={photoOfMe}
alt=""
sizes="(min-width: 1024px) 32rem, 20rem"
className="aspect-square shadow-inner rounded-2xl bg-zinc-100 object-cover dark:bg-zinc-800 rotate-3"

View File

@ -199,7 +199,7 @@ export default function Home({articles}: { articles: Article[] }) {
/>
<meta
property="og:image"
content="/static/images/photo-of-me-lg.jpg"
content="/static/images/photo-of-me-og.jpg"
/>
<meta
name="twitter:card"
@ -219,7 +219,7 @@ export default function Home({articles}: { articles: Article[] }) {
content="Full-stack software engineer who enjoys building cloud-native applications."/>
<meta
name="twitter:image"
content="/static/images/photo-of-me-lg.jpg"
content="/static/images/photo-of-me-og.jpg"
/>
</Head>
<Container className="mt-9">

View File

Before

Width:  |  Height:  |  Size: 291 KiB

After

Width:  |  Height:  |  Size: 291 KiB

View File

Before

Width:  |  Height:  |  Size: 53 KiB

After

Width:  |  Height:  |  Size: 53 KiB

View File

Before

Width:  |  Height:  |  Size: 166 KiB

After

Width:  |  Height:  |  Size: 166 KiB

View File

Before

Width:  |  Height:  |  Size: 482 KiB

After

Width:  |  Height:  |  Size: 482 KiB

View File

@ -1,6 +1,6 @@
/** @type {import('tailwindcss').Config} */
module.exports = {
content: ['./src/**/*.{js,jsx,tsx}'],
content: ['./pages/**/*.{js,jsx,tsx}', './components/**/*.{js,jsx,tsx}'],
darkMode: 'class',
plugins: [
require('@tailwindcss/typography'),

View File

@ -21,7 +21,7 @@
"baseUrl": ".",
"paths": {
"@/*": [
"src/*"
"*"
]
}
},