aboutsummaryrefslogtreecommitdiff
path: root/bench/snippets/write-file.mjs
blob: 4417c817cd5caefe146edd682929d10c5a5b558d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import { readFileSync, writeFileSync } from "node:fs";
import { bench, run } from "./runner.mjs";

var short = "Hello World!";
var shortUTF16 = "Hello World 💕💕💕";
var long = "Hello World!".repeat(1024);
var longUTF16 = "Hello World 💕💕💕".repeat(1024);

bench(`${short.length} ascii`, () => {
  writeFileSync("/tmp/bun.bench-out.txt", short);
});

bench(`${short.length} utf8`, () => {
  writeFileSync("/tmp/bun.bench-out.txt", shortUTF16);
});

bench(`${long.length} ascii`, () => {
  writeFileSync("/tmp/bun.bench-out.txt", long);
});

bench(`${longUTF16.length} utf8`, () => {
  writeFileSync("/tmp/bun.bench-out.txt", longUTF16);
});

await run();
ption value='restart-on-lock'>restart-on-lock Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/scripts/cmd/prebuild.js (unfollow)
AgeCommit message (Collapse)AuthorFilesLines
2025-01-02fix: injected route entrypoint (#12816)Gravatar Emanuele Stoppa 2-1/+12
2025-01-02fix: missing log (#12814)Gravatar Emanuele Stoppa 2-8/+25
2025-01-02fix: pass emulated entry to getCollection filter function (#12875)Gravatar Matt Kane 4-8/+32
* fix: pass emulated entry to getCollection filter function * Add test
2025-01-02[ci] formatGravatar Emanuele Stoppa 1-1/+1
2025-01-02fix(core): add error log for server islands (#12768)Gravatar Emanuele Stoppa 9-8/+34
Co-authored-by: Sarah Rainsberger <5098874+sarah11918@users.noreply.github.com> Co-authored-by: Matt Kane <m@mk.gg>
2025-01-02fix: pass cookie options to delete (#12820)Gravatar Matt Kane 3-16/+26
2025-01-02fix: session regeneration (#12864)Gravatar Chris Kanich 3-2/+53
Co-authored-by: Matt Kane <m@mk.gg> Co-authored-by: Emanuele Stoppa <my.burning@gmail.com>
2025-01-02Fix Vue & Svelte server renderer types (#12776)Gravatar Amine Ilidrissi 3-2/+12
Co-authored-by: Emanuele Stoppa <my.burning@gmail.com>
2025-01-02fix: make `reference()` a sync transform (#12781)Gravatar Matt Kane 3-4/+20
2024-12-31Fix sync-examples workflow (#12562)Gravatar Bjorn Lu 1-22/+20
2024-12-26fix(@astrojs/rss): revert incorrect Content-Type header applied for RSS XML ↵Gravatar Chloe Arciniega 3-2/+7
file (#12829) * fix: revert content-type changes * chore: changeset
2024-12-24patch: update partytown dependencies (#12822)Gravatar Scott Davis 4-15/+28
2024-12-23[ci] formatGravatar Louis Escher 1-1/+1
2024-12-23Fix server island script breaking when charset is added to content-type (#12810)Gravatar Louis Escher 5-1/+28
2024-12-20fix(toolbar): assign label to icons (#12734)Gravatar Emanuele Stoppa 3-6/+6
2024-12-20fix: better logs for invalid content config (#12798)Gravatar Matt Kane 6-4/+69
Co-authored-by: Chris Swithinbank <swithinbank@gmail.com>
2024-12-20[ci] release (#12790)astro@5.1.1@astrojs/vue@5.0.3@astrojs/tailwind@5.1.4@astrojs/svelte@7.0.2@astrojs/studio@0.1.3@astrojs/solid-js@5.0.1@astrojs/react@4.1.2@astrojs/preact@4.0.1@astrojs/mdx@4.0.3@astrojs/markdoc@0.12.4@astrojs/db@0.14.5@astrojs/alpinejs@0.4.1Gravatar Houston (Bot) 51-124/+177
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-12-20fix(deps): upgrade Vite (#12799)Gravatar Matt Kane 14-84/+152
2024-12-20update comment in packages/astro/src/types/public/common.ts (#12782)Gravatar Hiromasa Fujimori 2-1/+6
2024-12-19[ci] formatGravatar Matt Kane 1-4/+2
2024-12-19fix: pass raw frontmatter to when parsing markdown in glob loader (#12789)Gravatar Matt Kane 13-1/+171
2024-12-19chore: move files to `.mjs` (#12765)Gravatar Emanuele Stoppa 2-0/+0
2024-12-19chore: fix links in session errors (#12787)Gravatar Matt Kane 1-4/+4
2024-12-19[ci] release (#12762)astro@5.1.0Gravatar Houston (Bot) 33-159/+140
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>