mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-17 01:56:27 +08:00
chore: add crossorigin to resource tags (#12031)
<!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Added the crossorigin attribute to all CSS and JavaScript tags in generated HTML, improving compatibility for cross-origin resource loading. - **Tests** - Updated tests to verify the presence of the crossorigin attribute in script tags. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
@@ -64,7 +64,7 @@ test('should render correct html', async t => {
|
||||
|
||||
t.true(
|
||||
res.text.includes(
|
||||
`<script src="https://app.affine.pro/main.a.js"></script>`
|
||||
`<script src="https://app.affine.pro/main.a.js" crossorigin></script>`
|
||||
)
|
||||
);
|
||||
});
|
||||
@@ -78,7 +78,7 @@ test.skip('should render correct mobile html', async t => {
|
||||
|
||||
t.true(
|
||||
res.text.includes(
|
||||
`<script src="https://app.affine.pro/main.c.js"></script>`
|
||||
`<script src="https://app.affine.pro/main.c.js" crossorigin></script>`
|
||||
)
|
||||
);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user