Skip to content

Commit 8e2f994

Browse files
committed
docs: Revise CSP policy
1 parent f6a9fda commit 8e2f994

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

  • plugins/ui5-guidelines/skills/ui5-best-practices

plugins/ui5-guidelines/skills/ui5-best-practices/SKILL.md

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -241,6 +241,10 @@ When modifying `.properties` files, follow the appropriate workflow based on you
241241
alert("Hello");
242242
</script>
243243

244+
<style>
245+
.error { color: red; }
246+
</style>
247+
244248
<div style="color: red;">Styled text</div>
245249

246250
<!-- ✅ CORRECT - External files -->
@@ -253,8 +257,10 @@ When modifying `.properties` files, follow the appropriate workflow based on you
253257

254258
**Requirements**:
255259
- All application logic must reside in dedicated JS or TS files
256-
- All styling must reside in dedicated CSS files and use CSS classes/IDs
257-
- Inline `<script>` and inline `style` attributes violate CSP
260+
- All styling must reside in dedicated CSS files
261+
- Inline `<script>` tags violate CSP
262+
- Inline `<style>` tags violate CSP
263+
- Inline `style` attributes violate CSP
258264

259265
**Reference**: UI5 documentation page "Content Security Policy"
260266

0 commit comments

Comments
 (0)