You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/Best_Practices_for_Developers_28fcd55.md
+6-6Lines changed: 6 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -210,7 +210,7 @@ In the following we'll focus on crucial aspects of app development, specifically
210
210
When creating instances of OpenUI5 controls programmatically \(i.e. not declaratively via XML View or Fragment\), then:
211
211
212
212
- Don't use the global name of a control. Require the corresponding module dependency instead.
213
-
- Use `createId` to ensure there are no ID collisions, e.g. `View.createId` to prefix the control's ID with the view ID.
213
+
- Use `createId` to ensure there are no ID collisions, e.g. [`sap.ui.core.mvc.View#createId`](https://sdk.openui5.org/api/sap.ui.core.mvc.View%23methods/createId) to prefix the control's ID with the view ID.
214
214
215
215
**Additional Information:**
216
216
@@ -323,14 +323,14 @@ Take care of destroying programatically created models to prevent memory leaks.
323
323
324
324
**OData V2 Model**
325
325
326
-
- [`v2.ODataModel#createEntry`](https://sdk.openui5.org/api/sap.ui.model.odata.v2.ODataModel%23methods/createEntry): Defining an array for the `mParameters.properties` is deprecated since OpenUI5 1.120. Pass the initial values as an object instead.
326
+
- [`v2.ODataModel#createEntry`](https://sdk.openui5.org/api/sap.ui.model.odata.v2.ODataModel%23methods/createEntry): Defining an array for the `mParameters.properties` is deprecated since OpenUI5 1.120. Pass the initial values as an object instead.
327
327
328
-
- [`v2.ODataModel#refreshSecurityToken`](https://sdk.openui5.org/api/sap.ui.model.odata.v2.ODataModel%23methods/refreshSecurityToken): Pass `true` for the `bAsync` parameter explicitly as its default value is `false`.
328
+
- [`v2.ODataModel#refreshSecurityToken`](https://sdk.openui5.org/api/sap.ui.model.odata.v2.ODataModel%23methods/refreshSecurityToken): Pass `true` for the `bAsync` parameter explicitly as its default value is `false`.
329
329
330
330
331
331
**JSON Model**
332
332
333
-
[`JSONModel#loadData`](https://sdk.openui5.org/api/sap.ui.model.json.JSONModel%23methods/loadData): Do **not** pass `false` to the `bAsync` and `bCache` parameters, which are deprecated.
333
+
[`JSONModel#loadData`](https://sdk.openui5.org/api/sap.ui.model.json.JSONModel%23methods/loadData): Do **not** pass `false` to the `bAsync` and `bCache` parameters, which are deprecated.
- Ensure a dependency on the renderer or embed it within the control class.
366
366
367
-
- Migrate to the rendering `apiVersion 2` or `apiVersion 4`.For more information, see the [API Reference](https://sdk.openui5.org/api/sap.ui.core.RenderManager%23overview).
367
+
- Migrate to the rendering `apiVersion 2` or `apiVersion 4`.For more information, see the [API Reference](https://sdk.openui5.org/api/sap.ui.core.RenderManager%23overview).
368
368
369
369
- When utilizing [`RenderManager#icon`](https://sdk.openui5.org/api/sap.ui.core.RenderManager%23methods/icon) during rendering, include a dependency to `sap/ui/core/IconPool` in your code.
- Don't use the global namespace of the library to add types. Use the return value of `Lib.init` instead to add them.
392
392
393
-
- Migrate to the library `apiVersion 2`.For more information, see the [API Reference](https://sdk.openui5.org/api/sap.ui.core.Lib%23methods/sap.ui.core.Lib.init).
393
+
- Migrate to the library `apiVersion 2`.For more information, see the [API Reference](https://sdk.openui5.org/api/sap.ui.core.Lib%23methods/sap.ui.core.Lib.init).
394
394
395
395
- Use [`sap.ui.base.DataType.registerEnum`](https://sdk.openui5.org/api/sap.ui.base.DataType%23methods/sap.ui.base.DataType.registerEnum) to register enums that shall be usable as a type of control properties.
0 commit comments