Skip to content

Commit 95331a8

Browse files
Copilotbrunoborges
andcommitted
Fix AOT caching commands and copy button functionality
Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
1 parent 4079dd4 commit 95331a8

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

aot-class-preloading.html

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -131,12 +131,10 @@ <h1>AOT class preloading</h1>
131131
</div>
132132
<div class="compare-code">
133133
<pre class="code-text">// Training run:
134-
$ java -XX:AOTMode=record \
135-
-XX:AOTConfiguration=app.aotconf \
134+
$ java -XX:AOTCacheOutput=app.aot \
136135
-cp app.jar com.App
137136
// Production:
138-
$ java -XX:AOTMode=on \
139-
-XX:AOTCache=app.aot \
137+
$ java -XX:AOTCache=app.aot \
140138
-cp app.jar com.App</pre>
141139
</div>
142140
</div>

app.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,7 @@
198198
btn.addEventListener('click', () => {
199199
// Find adjacent code block
200200
const codeBlock = btn.closest('.code-header')?.nextElementSibling
201+
|| btn.closest('.compare-panel-header')?.nextElementSibling?.querySelector('pre, code, .code-text')
201202
|| btn.parentElement?.querySelector('pre, code, .code-text');
202203
if (!codeBlock) return;
203204

0 commit comments

Comments
 (0)