blaze-performance-tester 3.1.10 → 3.1.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +80 -2
- package/dist/index.win32-x64-msvc.node +0 -0
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -475,7 +475,6 @@ function processMetricsTelemetry(requests, durationSec, apdexT) {
|
|
|
475
475
|
let c1xx = 0, c2xx = 0, c3xx = 0, c4xx = 0, c5xx = 0;
|
|
476
476
|
let econnresetCount = 0;
|
|
477
477
|
let econnrefusedCount = 0;
|
|
478
|
-
const targetCodes = [400, 401, 403, 404, 429, 500, 502, 503, 504];
|
|
479
478
|
const codeCounts = { 400: 0, 401: 0, 403: 0, 404: 0, 429: 0, 500: 0, 502: 0, 503: 0, 504: 0 };
|
|
480
479
|
requests.forEach((r) => {
|
|
481
480
|
if (r.statusCode >= 100 && r.statusCode < 200) c1xx++;
|
|
@@ -492,7 +491,7 @@ function processMetricsTelemetry(requests, durationSec, apdexT) {
|
|
|
492
491
|
}
|
|
493
492
|
});
|
|
494
493
|
const codeRates = {};
|
|
495
|
-
|
|
494
|
+
Object.keys(codeCounts).forEach((code) => {
|
|
496
495
|
codeRates[code] = totalRequests === 0 ? 0 : codeCounts[code] / totalRequests * 100;
|
|
497
496
|
});
|
|
498
497
|
const econnresetRate = totalRequests === 0 ? 0 : econnresetCount / totalRequests * 100;
|
|
@@ -581,6 +580,84 @@ function exportHtmlDashboard(history, config, verdictReason, semanticReport, res
|
|
|
581
580
|
const lcpStat = getLcpStatus(cards.lcp);
|
|
582
581
|
const fidStat = getFidStatus(cards.fid);
|
|
583
582
|
const clsStat = getClsStatus(cards.cls);
|
|
583
|
+
const lcp = cards.lcp;
|
|
584
|
+
let seoScore = 100;
|
|
585
|
+
let visibilityLossPct = 0;
|
|
586
|
+
let trafficDropPct = 0;
|
|
587
|
+
let rankDropPositions = 0;
|
|
588
|
+
if (lcp > 2500) {
|
|
589
|
+
if (lcp <= 4e3) {
|
|
590
|
+
const ratio = (lcp - 2500) / 1500;
|
|
591
|
+
seoScore = 100 - ratio * 30;
|
|
592
|
+
visibilityLossPct = ratio * 14.5;
|
|
593
|
+
trafficDropPct = ratio * 18.2;
|
|
594
|
+
rankDropPositions = Number((ratio * 1.2).toFixed(1));
|
|
595
|
+
} else {
|
|
596
|
+
const ratio = Math.min(1, (lcp - 4e3) / 4e3);
|
|
597
|
+
seoScore = Math.max(8, 70 - ratio * 62);
|
|
598
|
+
visibilityLossPct = 14.5 + ratio * 52;
|
|
599
|
+
trafficDropPct = 18.2 + ratio * 58.5;
|
|
600
|
+
rankDropPositions = Number((1.2 + ratio * 4.6).toFixed(1));
|
|
601
|
+
}
|
|
602
|
+
}
|
|
603
|
+
let seoColor = "#10b981";
|
|
604
|
+
let seoStatus = "EXCELLENT";
|
|
605
|
+
if (seoScore < 90) {
|
|
606
|
+
seoColor = "#f59e0b";
|
|
607
|
+
seoStatus = "NEEDS IMPROVEMENT";
|
|
608
|
+
}
|
|
609
|
+
if (seoScore < 60) {
|
|
610
|
+
seoColor = "#ef4444";
|
|
611
|
+
seoStatus = "CRITICAL RISK / PENALIZED";
|
|
612
|
+
}
|
|
613
|
+
const seoPredictorPanelHtml = `
|
|
614
|
+
<div class="card" style="margin-top: 2rem; background: #131c2e; border: 1px solid #1e293b;">
|
|
615
|
+
<h3 style="color: #38bdf8; font-size: 1.2rem; border-bottom: none; margin-bottom: 0.25rem;">
|
|
616
|
+
\u{1F50D} Google SEO Rank & Search Visibility Impact Predictor
|
|
617
|
+
</h3>
|
|
618
|
+
<div style="color: #94a3b8; font-size: 0.9rem; margin-bottom: 1.5rem;">
|
|
619
|
+
Predictive algorithmic simulation modeling response degradation metrics directly against Google Core Web Vitals signal rules.
|
|
620
|
+
</div>
|
|
621
|
+
|
|
622
|
+
<div style="display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; flex-wrap: wrap;">
|
|
623
|
+
<div style="background: #090d16; padding: 1.25rem; border-radius: 6px; border: 1px solid #1e293b; text-align: center;">
|
|
624
|
+
<div style="font-size: 0.75rem; color: #64748b; text-transform: uppercase; font-weight: bold;">Core Web Vitals SEO Score</div>
|
|
625
|
+
<div style="font-size: 1.8rem; font-weight: bold; color: ${seoColor}; margin-top: 0.25rem;">
|
|
626
|
+
${seoScore.toFixed(0)}<span style="font-size: 1rem; color: #94a3b8;">/100</span>
|
|
627
|
+
</div>
|
|
628
|
+
<div style="font-size: 0.75rem; font-weight: bold; margin-top: 0.4rem; color: ${seoColor};">${seoStatus}</div>
|
|
629
|
+
</div>
|
|
630
|
+
|
|
631
|
+
<div style="background: #090d16; padding: 1.25rem; border-radius: 6px; border: 1px solid #1e293b; text-align: center;">
|
|
632
|
+
<div style="font-size: 0.75rem; color: #64748b; text-transform: uppercase; font-weight: bold;">Search Visibility Loss</div>
|
|
633
|
+
<div style="font-size: 1.8rem; font-weight: bold; color: ${visibilityLossPct > 0 ? "#ef4444" : "#10b981"}; margin-top: 0.25rem;">
|
|
634
|
+
-${visibilityLossPct.toFixed(1)}%
|
|
635
|
+
</div>
|
|
636
|
+
<div style="font-size: 0.75rem; color: #64748b; margin-top: 0.4rem;">Projected SERP Impression Drop</div>
|
|
637
|
+
</div>
|
|
638
|
+
|
|
639
|
+
<div style="background: #090d16; padding: 1.25rem; border-radius: 6px; border: 1px solid #1e293b; text-align: center;">
|
|
640
|
+
<div style="font-size: 0.75rem; color: #64748b; text-transform: uppercase; font-weight: bold;">Est. Organic Traffic Loss</div>
|
|
641
|
+
<div style="font-size: 1.8rem; font-weight: bold; color: ${trafficDropPct > 0 ? "#ef4444" : "#10b981"}; margin-top: 0.25rem;">
|
|
642
|
+
-${trafficDropPct.toFixed(1)}%
|
|
643
|
+
</div>
|
|
644
|
+
<div style="font-size: 0.75rem; color: #64748b; margin-top: 0.4rem;">Expected funnel volume drop</div>
|
|
645
|
+
</div>
|
|
646
|
+
|
|
647
|
+
<div style="background: #090d16; padding: 1.25rem; border-radius: 6px; border: 1px solid #1e293b; text-align: center;">
|
|
648
|
+
<div style="font-size: 0.75rem; color: #64748b; text-transform: uppercase; font-weight: bold;">Avg SERP Position Shift</div>
|
|
649
|
+
<div style="font-size: 1.8rem; font-weight: bold; color: ${rankDropPositions > 0 ? "#f59e0b" : "#10b981"}; margin-top: 0.25rem;">
|
|
650
|
+
${rankDropPositions > 0 ? `+${rankDropPositions}` : "0.0"}
|
|
651
|
+
</div>
|
|
652
|
+
<div style="font-size: 0.75rem; color: #64748b; margin-top: 0.4rem;">Rank places dropped down standard index</div>
|
|
653
|
+
</div>
|
|
654
|
+
</div>
|
|
655
|
+
|
|
656
|
+
<div style="margin-top: 1rem; background: #090d16; padding: 1rem; border-radius: 6px; border: 1px solid #1e293b; font-size: 0.85rem; line-height: 1.5; color: #cbd5e1;">
|
|
657
|
+
<strong>\u{1F52E} SEO Engine Intelligence Breakdown:</strong>
|
|
658
|
+
${lcp <= 2500 ? "Your simulated Largest Contentful Paint equivalent falls safely within Google's 'Good' range (≤ 2500ms). The parsing layer calculates zero performance-based rank penalties under current system load profiles." : lcp <= 4e3 ? `Warning: Current concurrency load has pushed LCP to ${lcp.toFixed(0)}ms, landing in Google's 'Needs Improvement' window. This response drag risks triggering index rank adjustments, potentially demoting listings down by ~${rankDropPositions} positions and sacrificing around ${trafficDropPct.toFixed(0)}% of organic top-of-funnel users.` : `Critical Signal Breach: Load performance has forced LCP to ${lcp.toFixed(0)}ms, severely violating Google's 'Poor' performance ceiling (> 4000ms). At this level, ranking algorithms actively de-weight domains. Expect structural search visibility erosion up to ${visibilityLossPct.toFixed(0)}% and immediate organic traffic traffic redirection.`}
|
|
659
|
+
</div>
|
|
660
|
+
</div>`;
|
|
584
661
|
const connectionDiagnosticsPanelHtml = `
|
|
585
662
|
<div class="card" style="margin-top: 2rem; background: #131c2e; border: 1px solid #1e293b;">
|
|
586
663
|
<h3 style="color: #38bdf8; font-size: 1.2rem; border-bottom: none; margin-bottom: 0.25rem;">
|
|
@@ -957,6 +1034,7 @@ function exportHtmlDashboard(history, config, verdictReason, semanticReport, res
|
|
|
957
1034
|
</tbody>
|
|
958
1035
|
</table>
|
|
959
1036
|
</div>
|
|
1037
|
+
${seoPredictorPanelHtml}
|
|
960
1038
|
${connectionDiagnosticsPanelHtml}
|
|
961
1039
|
${liveAdjusterHtml}
|
|
962
1040
|
${rightSizingHtml}
|
|
Binary file
|