Functions
check_alpine_cdn_urls
1
list[ContractIssue]
▼
Flag bare jsDelivr Alpine CDN URLs in template sources.
A bare ``alpinejs@`` U…
check_alpine_cdn_urls
1
list[ContractIssue]
▼
def check_alpine_cdn_urls(template_sources: dict[str, str]) -> list[ContractIssue]
Flag bare jsDelivr Alpine CDN URLs in template sources.
A barealpinejs@<version> URL (no /dist/cdn.min.js) loads the
CommonJS build, which throwsReferenceError: module is not defined
in the browser and is silenced by CORS. Every Alpine-powered component
will quietly stop working.
Parameters
| Name | Type | Description |
|---|---|---|
template_sources |
dict[str, str] |
Returns
list[ContractIssue]