fix(scrape): remove style tags from blocks before extracting any content

This commit is contained in:
2026-03-07 22:40:20 +09:00
parent 4242b47fe8
commit 30174a60f6

View File

@@ -146,6 +146,9 @@ class CDPClient {
// placeholder 개별 블록도 건너뛰기
if (block.classList.contains('bg-gray-500/10') && block.textContent.trim() === '') continue;
// 블록 내 style 태그 제거 (CSS 코드 누출 방지)
block.querySelectorAll('style').forEach(s => s.remove());
// --- 작업 카드 (task boundary) ---
const taskCard = block.querySelector('.isolate');
if (taskCard || block.classList.contains('isolate')) {