Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions benchmark/react/cases/006-static-raw-text/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
// Copyright 2025 The Lynx Authors. All rights reserved.
// Licensed under the Apache License Version 2.0 that can be found in the
// LICENSE file in the root directory of this source tree.

import { root } from '@lynx-js/react';

import { RunBenchmarkUntilHydrate } from '../../src/RunBenchmarkUntil.js';

runAfterLoadScript(() => {
root.render(
<>
{Array.from(
{ length: 100 },
() => (
<text>
Hello, ReactLynx 🎉!
</text>
),
)}
<RunBenchmarkUntilHydrate />
</>,
);
});
4 changes: 4 additions & 0 deletions benchmark/react/lynx.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@ export default defineConfig({
'005-load-script': [
'./cases/005-load-script/index.tsx',
],
'006-static-raw-text': [
'./src/patchProfile.ts',
'./cases/006-static-raw-text/index.tsx',
],
},
},
plugins: [
Expand Down
2 changes: 2 additions & 0 deletions benchmark/react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"bench:003-hello-list": "benchx_cli run dist/003-hello-list.lynx.bundle --wait-for-id=stop-benchmark-true",
"bench:004-various-update": "benchx_cli run dist/004-various-update.lynx.bundle --wait-for-id=stop-benchmark-true",
"bench:005-load-script": "benchx_cli run dist/005-load-script.lynx.bundle",
"bench:006-static-raw-text": "benchx_cli run dist/006-static-raw-text.lynx.bundle --wait-for-id=stop-benchmark-true",
"build": "rspeedy build",
"dev": "rspeedy dev",
"perfetto": "pnpm run --sequential --stream --aggregate-output '/^perfetto:.*/'",
Expand All @@ -18,6 +19,7 @@
"perfetto:003-hello-list": "benchx_cli -o dist/003-hello-list.ptrace run dist/003-hello-list.lynx.bundle --wait-for-id=stop-benchmark-true",
"perfetto:004-various-update": "benchx_cli -o dist/004-various-update.ptrace run dist/004-various-update.lynx.bundle --wait-for-id=stop-benchmark-true",
"perfetto:005-load-script": "benchx_cli -o dist/005-load-script.ptrace run dist/005-load-script.lynx.bundle",
"perfetto:006-static-raw-text": "benchx_cli -o dist/006-static-raw-text.ptrace run dist/006-static-raw-text.lynx.bundle --wait-for-id=stop-benchmark-true",
"test": "echo 'No tests specified'"
},
"dependencies": {
Expand Down
2 changes: 1 addition & 1 deletion vitest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export default defineConfig({
'website/**',

'packages/react/transform/tests/__swc_snapshots__/**',
'packages/rspeedy/create-rspeedy/template-*/**',
'**/tests/__swc_snapshots__/**',

'.lintstagedrc.mjs',
'eslint.config.js',
Expand Down
Loading