Skip to content

Commit 2a6c2b0

Browse files
committed
Tried coloring just after adding code
1 parent ec91521 commit 2a6c2b0

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

script.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -287,6 +287,7 @@ async function renderProblemPage(platform, problemName) {
287287
pageContent += `</div>`;
288288

289289
main.innerHTML = pageContent;
290+
hljs.highlightAll();
290291
document.title = `${pageTitle} - ${platformTitle}`;
291292

292293
if (!document.querySelector('link[rel="icon"]')) {
@@ -402,8 +403,3 @@ window.addEventListener('hashchange', () => {
402403
location.reload(); // Reload to show main page
403404
}
404405
});
405-
406-
407-
window.onload = () => {
408-
hljs.highlightAll();
409-
}

0 commit comments

Comments
 (0)