Adds a better test for benchmarking (#4966)

* Rendering: speed up rendering of HTML chunks

* Add a changeset

* Remove the fix

* remove the changeset
This commit is contained in:
Matthew Phillips 2022-10-03 17:02:02 -04:00 committed by GitHub
parent 906ac622ca
commit c6ab0206cb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 77 additions and 7 deletions

View file

@ -2,7 +2,8 @@
"name": "@benchmark/simple",
"scripts": {
"start": "node server.mjs",
"build": "astro build"
"build": "astro build",
"dev": "astro dev"
},
"dependencies": {
"astro": "workspace:*",

View file

@ -1,9 +1,78 @@
---
import Layout from '../components/Layout.astro';
const name = 'world';
const content = "Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum. Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.";
---
<Layout title={`Index page`}>
<h1>index page</h1>
<h2>Hello {name}</h2>
</Layout>
<html lang="en">
<head>
<meta charset="utf-8" />
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
<meta name="viewport" content="width=device-width" />
<meta name="generator" content={Astro.generator} />
<title>Astro</title>
</head>
<body>
<h1>Astro</h1>
<div>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
<p>{content}</p>
</div>
</body>
</html>