File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ import { fetchPerformanceMetrics } from './fetchPerformanceMetrics.ts'
66import { markdownArray , type Pr } from './reportAsAPrComment.ts'
77
88// The value is set to 5% as it's around 10 times the average value for small PRs.
9- const SIZE_INCREASE_THRESHOLD = 5
9+ const SIZE_INCREASE_THRESHOLD = 0.05
1010
1111export async function computeAndReportBundleSizes ( pr ?: Pr ) {
1212 const localBundleSizes = extractUncompressedBundleSizes ( calculateBundleSizes ( ) )
@@ -84,7 +84,7 @@ export function formatBundleSizes({
8484 } )
8585
8686 if ( highIncreaseDetected ) {
87- message += `\n⚠️ The increase is particularly high and exceeds ${ SIZE_INCREASE_THRESHOLD } % . Please check the changes.`
87+ message += `\n⚠️ The increase is particularly high and exceeds ${ formatPercentage ( SIZE_INCREASE_THRESHOLD ) } . Please check the changes.`
8888 }
8989
9090 return message
You can’t perform that action at this time.
0 commit comments