Summary
There are 54 occurrences of the deprecated .substr() method across 34 files in the codebase. While .substr() still works in all runtimes (it's in Annex B of the spec), it has been deprecated in favor of .substring() or .slice().
Pattern
All instances follow the same ID generation pattern:
Math.random().toString(36).substr(2, 9)
// should become:
Math.random().toString(36).substring(2, 11)
Affected Plugins
browser-automation-test-recorder (20 occurrences across 14 files)
memory-performance-profiler (3 occurrences)
logger-devtools (2 occurrences)
api-mock-interceptor (2 occurrences)
feature-flag-manager (2 occurrences)
bundle-impact-analyzer, stress-testing-devtools, security-audit-panel, graphql-devtools, render-waste-detector, router-devtools, visual-regression-monitor, error-boundary-visualizer (1 each)
Migration
.substr(start, length) → .substring(start, start + length)
| Before |
After |
.substr(2, 9) |
.substring(2, 11) |
.substr(2, 6) |
.substring(2, 8) |
.substr(2, 10) |
.substring(2, 12) |
.substr(2, 16) |
.substring(2, 18) |
.substr(2, 32) |
.substring(2, 34) |
.substr(2) |
.substring(2) |
.substr(0, 6) |
.substring(0, 6) |
.substr(0, 8) |
.substring(0, 8) |
Priority
Low — no runtime impact, but good hygiene for modern JavaScript standards.
Summary
There are 54 occurrences of the deprecated
.substr()method across 34 files in the codebase. While.substr()still works in all runtimes (it's in Annex B of the spec), it has been deprecated in favor of.substring()or.slice().Pattern
All instances follow the same ID generation pattern:
Affected Plugins
browser-automation-test-recorder(20 occurrences across 14 files)memory-performance-profiler(3 occurrences)logger-devtools(2 occurrences)api-mock-interceptor(2 occurrences)feature-flag-manager(2 occurrences)bundle-impact-analyzer,stress-testing-devtools,security-audit-panel,graphql-devtools,render-waste-detector,router-devtools,visual-regression-monitor,error-boundary-visualizer(1 each)Migration
.substr(start, length)→.substring(start, start + length).substr(2, 9).substring(2, 11).substr(2, 6).substring(2, 8).substr(2, 10).substring(2, 12).substr(2, 16).substring(2, 18).substr(2, 32).substring(2, 34).substr(2).substring(2).substr(0, 6).substring(0, 6).substr(0, 8).substring(0, 8)Priority
Low — no runtime impact, but good hygiene for modern JavaScript standards.