Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
haochengxu committed Sep 24, 2023
1 parent 82504ae commit f247c76
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 10 deletions.
6 changes: 3 additions & 3 deletions _posts/dynamic-routing.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
---
title: 'Dynamic Routing and Static Generation'
excerpt: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Praesent elementum facilisis leo vel fringilla est ullamcorper eget. At imperdiet dui accumsan sit amet nulla facilities morbi tempus.'
coverImage: 'assets/blog/dynamic-routing/cover.jpg'
coverImage: '/assets/blog/dynamic-routing/cover.jpg'
date: '2020-03-16T05:35:07.322Z'
author:
name: JJ Kasper
picture: 'assets/blog/authors/jj.jpeg'
picture: '/assets/blog/authors/jj.jpeg'
ogImage:
url: 'assets/blog/dynamic-routing/cover.jpg'
url: '/assets/blog/dynamic-routing/cover.jpg'
---

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Praesent elementum facilisis leo vel fringilla est ullamcorper eget. At imperdiet dui accumsan sit amet nulla facilities morbi tempus. Praesent elementum facilisis leo vel fringilla. Congue mauris rhoncus aenean vel. Egestas sed tempus urna et pharetra pharetra massa massa ultricies.
Expand Down
6 changes: 3 additions & 3 deletions _posts/hello-world.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
---
title: 'Learn How to Pre-render Pages Using Static Generation with Next.js'
excerpt: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Praesent elementum facilisis leo vel fringilla est ullamcorper eget. At imperdiet dui accumsan sit amet nulla facilities morbi tempus.'
coverImage: 'assets/blog/hello-world/cover.jpg'
coverImage: '/assets/blog/hello-world/cover.jpg'
date: '2020-03-16T05:35:07.322Z'
author:
name: Tim Neutkens
picture: 'assets/blog/authors/tim.jpeg'
picture: '/assets/blog/authors/tim.jpeg'
ogImage:
url: 'assets/blog/hello-world/cover.jpg'
url: '/assets/blog/hello-world/cover.jpg'
---

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Praesent elementum facilisis leo vel fringilla est ullamcorper eget. At imperdiet dui accumsan sit amet nulla facilities morbi tempus. Praesent elementum facilisis leo vel fringilla. Congue mauris rhoncus aenean vel. Egestas sed tempus urna et pharetra pharetra massa massa ultricies.
Expand Down
6 changes: 3 additions & 3 deletions _posts/preview.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
---
title: 'Preview Mode for Static Generation'
excerpt: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Praesent elementum facilisis leo vel fringilla est ullamcorper eget. At imperdiet dui accumsan sit amet nulla facilities morbi tempus.'
coverImage: 'assets/blog/preview/cover.jpg'
coverImage: '/assets/blog/preview/cover.jpg'
date: '2020-03-16T05:35:07.322Z'
author:
name: Joe Haddad
picture: 'assets/blog/authors/joe.jpeg'
picture: '/assets/blog/authors/joe.jpeg'
ogImage:
url: 'assets/blog/preview/cover.jpg'
url: '/assets/blog/preview/cover.jpg'
---

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Praesent elementum facilisis leo vel fringilla est ullamcorper eget. At imperdiet dui accumsan sit amet nulla facilities morbi tempus. Praesent elementum facilisis leo vel fringilla. Congue mauris rhoncus aenean vel. Egestas sed tempus urna et pharetra pharetra massa massa ultricies.
Expand Down
4 changes: 3 additions & 1 deletion image-loader.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
const prefix = process.env.NEXT_PUBLIC_BASE_PATH || '';

export default function imageLoader({
src,
width,
Expand All @@ -7,5 +9,5 @@ export default function imageLoader({
width: number
quality?: number
}) {
return src
return `${prefix}${src}`
}

0 comments on commit f247c76

Please sign in to comment.