Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -198,11 +198,11 @@ Published under [MIT License](./LICENSE).

## Star History

<a href="https://www.star-history.com/?repos=npmx-dev%2Fnpmx.dev&type=date&legend=top-left">
<a href="https://star-history.dera.page/#npmx-dev/npmx.dev&type=date&legend=top-left">
<picture>
<source media="(prefers-color-scheme: dark)" srcset="https://api.star-history.com/chart?repos=npmx-dev/npmx.dev&type=date&theme=dark&legend=top-left&sealed_token=1RI8ZdgQL3NncQeMm3sTwgYPL_7_ELdIGe5yiswir2iZipZwBtsYd4Y6zkO2fZLUP3wRcDN38GLKA4B1b3JE3pxEg7x_w8uOivwT3rL8Jcr-866HKSRMpjqmEwPavKp57ZdTyo04KHRbKthXVe360AJhcjmbXWxKVO9EDFh995ssNIH32hNArVB4MwAm" />
<source media="(prefers-color-scheme: light)" srcset="https://api.star-history.com/chart?repos=npmx-dev/npmx.dev&type=date&legend=top-left&sealed_token=1RI8ZdgQL3NncQeMm3sTwgYPL_7_ELdIGe5yiswir2iZipZwBtsYd4Y6zkO2fZLUP3wRcDN38GLKA4B1b3JE3pxEg7x_w8uOivwT3rL8Jcr-866HKSRMpjqmEwPavKp57ZdTyo04KHRbKthXVe360AJhcjmbXWxKVO9EDFh995ssNIH32hNArVB4MwAm" />
<img alt="Star History Chart" src="https://api.star-history.com/chart?repos=npmx-dev/npmx.dev&type=date&legend=top-left&sealed_token=1RI8ZdgQL3NncQeMm3sTwgYPL_7_ELdIGe5yiswir2iZipZwBtsYd4Y6zkO2fZLUP3wRcDN38GLKA4B1b3JE3pxEg7x_w8uOivwT3rL8Jcr-866HKSRMpjqmEwPavKp57ZdTyo04KHRbKthXVe360AJhcjmbXWxKVO9EDFh995ssNIH32hNArVB4MwAm" />
<source media="(prefers-color-scheme: dark)" srcset="https://star-history.dera.page/svg?repos=npmx-dev/npmx.dev&type=date&theme=dark&legend=top-left" />
<source media="(prefers-color-scheme: light)" srcset="https://star-history.dera.page/svg?repos=npmx-dev/npmx.dev&type=date&legend=top-left" />
<img alt="Star History Chart" src="https://star-history.dera.page/svg?repos=npmx-dev/npmx.dev&type=date&legend=top-left" />
Comment on lines +201 to +205

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Allow the new image origin in the page CSP before merging.

The <picture> sources and fallback <img> now request https://star-history.dera.page. modules/security-headers.ts:36-47 only lists https://api.star-history.com in img-src, so the rendered page can block the new chart images.

Add the new origin to the CSP allowlist. Update test/e2e/security-headers.spec.ts:3-22 to assert the new origin. Retain the legacy origin only if another page still uses it.

Suggested follow-up
 const cspOnlyImgOrigins = [
   'https://api.star-history.com',
+  'https://star-history.dera.page',
 ]

-expect(cspContent).toContain('https://api.star-history.com')
+expect(cspContent).toContain('https://star-history.dera.page')
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@README.md` around lines 201 - 205, Update the CSP image-source allowlist in
the security headers configuration to permit https://star-history.dera.page, and
update the security headers test to assert this origin is allowed. Remove
https://api.star-history.com only if no remaining page uses it.

</picture>
</a>

Expand Down
Loading