squirrelscan
GitHub

Source Maps

Checks for source map availability and configuration

Checks for source map availability and configuration

Rule ID perf/source-maps
Category Performance
Scope Per-page
Severity info
Weight 3/10

Solution

Source maps help debug minified code but can expose source code if publicly accessible. For production: 1) Either remove source maps entirely, 2) Restrict access via server config, or 3) Use ‘hidden’ source maps uploaded only to error tracking services. Exposed source maps can reveal business logic and security implementations to attackers.

Enable / Disable

Disable this rule

[rules]
disable = ["perf/source-maps"]

Disable all Performance rules

[rules]
disable = ["perf/*"]

Enable only this rule

[rules]
enable = ["perf/source-maps"]
disable = ["*"]

Type to search…

↑↓ navigate↵ openesc close