mirror of
https://github.com/hanzoai/next.js.git
synced 2026-09-24 17:00:51 +00:00
## Description This PR ensures that the default prettier config is used for examples and templates. This config is compatible with `prettier@3` as well (upgrading prettier is bigger change that can be a future PR). ## Changes - Updated `.prettierrc.json` in root with `"trailingComma": "es5"` (will be needed upgrading to prettier@3) - Added `examples/.prettierrc.json` with default config (this will change every example) - Added `packages/create-next-app/templates/.prettierrc.json` with default config (this will change every template) ## Related - Fixes #54402 - Closes #54409
43 lines
1.3 KiB
JavaScript
43 lines
1.3 KiB
JavaScript
import Link from "next/link";
|
|
|
|
import PostPreviewCondensed from "./post-preview-condensed";
|
|
|
|
export default function Blog({ posts }) {
|
|
return (
|
|
<section id="blog" className="blog-section">
|
|
<div className="container">
|
|
<div className="row justify-content-center">
|
|
<div className="col-lg-6 col-md-10">
|
|
<div className="section-title text-center">
|
|
<h2>Latest Blog Posts</h2>
|
|
<p>
|
|
Butter also has a built in blog engine which makes it dead
|
|
simple to launch a new company blog.
|
|
</p>
|
|
<p>
|
|
<Link href={`/blog`} className="main-btn btn-hover mt-5">
|
|
View All Blog Posts
|
|
</Link>
|
|
</p>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div className="row justify-content-center">
|
|
{posts.map((post) => (
|
|
<PostPreviewCondensed
|
|
key={post.slug}
|
|
title={post.title}
|
|
coverImage={post.featuredImage}
|
|
coverImageAlt={post.featuredImageAlt}
|
|
date={post.published}
|
|
author={post.author}
|
|
slug={post.slug}
|
|
excerpt={post.summary}
|
|
/>
|
|
))}
|
|
</div>
|
|
</div>
|
|
</section>
|
|
);
|
|
}
|