Fix Bootstrap Parameters
Key Rules
- ONLY modify the bootstrap
<script>tag (identified byid="sap-ui-bootstrap"orsrcmatchingsap-ui-core.js). All other<script>tags — including inline scripts, config blocks, and non-UI5 script references — MUST be preserved exactly as-is. They will be handled byfix-csp-compliancein a later phase. - Do not delete, move, or rewrite any
<script>block that is not the bootstrap tag. If the file has<script>window.config = {...}</script>before or after the bootstrap tag, leave it untouched.
This skill fixes HTML bootstrap parameter issues that the UI5 linter detects but cannot auto-fix because the changes may affect application behavior.
Linter Rules Handled
When to Use
Apply this skill when you see linter output like:
Fix Strategy
1. Locate the Bootstrap Script Tag
Find the <script> tag with either:
id="sap-ui-bootstrap"srcattribute matching pattern:sap-ui-core.js,sap-ui-custom.js,sap-ui-boot.js, etc.
2. Apply Fixes Based on Rule and Message
no-deprecated-api - Missing Parameters
Missing data-sap-ui-async: Add data-sap-ui-async="true"
Missing data-sap-ui-compat-version: Add data-sap-ui-compat-version="edge"
no-deprecated-api - Deprecated Values
data-sap-ui-async="false": Change to "true"
data-sap-ui-compat-version with non-edge value: Change to "edge"
no-deprecated-api - Abandoned Parameters (remove completely)
Remove these parameters entirely:
data-sap-ui-no-duplicate-ids- Enforced in modern UI5data-sap-ui-auto-aria-body-role- Removed in modern UI5data-sap-ui-manifest-first- Use Component.create manifest option insteaddata-sap-ui-origin-info- No longer supporteddata-sap-ui-areas- Use Control.placeAt insteaddata-sap-ui-trace- No longer supporteddata-sap-ui-xx-no-less- No longer supported
no-deprecated-api - Redundant Parameters
data-sap-ui-binding-syntax="simple"- Remove; complex syntax is enforced in modern UI5data-sap-ui-binding-syntax="complex"- Remove ifcompat-version="edge"is setdata-sap-ui-preloadwith invalid values - Remove
no-deprecated-api - Replaced Parameters
data-sap-ui-animation→data-sap-ui-animation-mode(converttrue→full,false→minimal)
no-deprecated-theme - Deprecated Themes
Replace with modern theme:
sap_bluecrystal→sap_horizonsap_belize→sap_horizonsap_belize_plus→sap_horizonsap_belize_hcb→sap_horizon_hcbsap_belize_hcw→sap_horizon_hcwsap_hcb→sap_horizon_hcbsap_ux→sap_horizonsap_platinum→sap_horizonsap_goldreflection→sap_horizon
no-deprecated-library - Deprecated Libraries
Remove deprecated libraries from data-sap-ui-libs:
sap.ui.commonssap.ui.ux3sap.makitsap.mesap.ca.uisap.sac.gridsap.ui.suitesap.zen.commonssap.zen.crosstabsap.zen.dsh
Implementation Steps
- Read the HTML file
- Parse to find the bootstrap script tag
- For each linter error (identified by rule ID and message):
- If missing parameter: Add the parameter with recommended value
- If deprecated value: Update to recommended value
- If abandoned/redundant: Remove the parameter
- If deprecated theme: Replace with modern theme
- If deprecated library: Remove from libs list
- Preserve formatting (indentation, line breaks) as much as possible
- Write the updated file
Example Fix
Given linter output:
Transform:
Notes
- Always add
data-sap-ui-async="true"before other data attributes for consistency - Setting
compat-version="edge"enables complex binding syntax automatically, sobinding-syntaxbecomes redundant - Removed parameters should not leave trailing whitespace or empty lines
- If the file has multiple script tags, only modify the bootstrap tag — leave all others intact (including inline
<script>blocks that will be handled by CSP compliance in Phase 5)


