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: packages/documentation/docs/updates/migrate-v3.md
+34-29Lines changed: 34 additions & 29 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,9 +1,10 @@
1
1
# Migrate to v3
2
2
3
-
!!! warning "Superseded"
4
-
**UI5 CLI 3.0 has been superseded by version 4.0. See [Migrate to v4](./migrate-v4.md).**
3
+
::: warning "Superseded"
4
+
**UI5 CLI 3.0 has been superseded by version 4.0. See [Migrate to v4](./migrate-v4.md).**
5
5
6
-
Find the announcement blog post for version 3.0 here: **[SAP Community: UI5 CLI 3.0](https://blogs.sap.com/2023/02/10/ui5-tooling-3.0/)**
6
+
Find the announcement blog post for version 3.0 here: **[SAP Community: UI5 CLI 3.0](https://blogs.sap.com/2023/02/10/ui5-tooling-3.0/)**
7
+
:::
7
8
8
9
## Node.js and npm Version Support
9
10
@@ -19,8 +20,9 @@ This means your old projects might still work. Unless they have non-standard con
19
20
20
21
## Changes for Projects
21
22
22
-
!!! info
23
-
✅ Projects defining **Specification Version 2.x** are expected to be **fully compatible with UI5 CLI v3**
23
+
::: info
24
+
✅ Projects defining **Specification Version 2.x** are expected to be **fully compatible with UI5 CLI v3**
25
+
:::
24
26
25
27
For projects defining the latest **Specification Versions 3.0 and higher**, some changes apply:
26
28
@@ -30,8 +32,9 @@ See also [Configuration: Specification Version 3.0](../pages/Configuration.md#sp
30
32
31
33
## Changes for Extensions
32
34
33
-
!!! info
34
-
✅ Custom Tasks and Custom Middleware defining **Specification Version 2.x** are expected to be **fully compatible with UI5 CLI v3**
35
+
::: info
36
+
✅ Custom Tasks and Custom Middleware defining **Specification Version 2.x** are expected to be **fully compatible with UI5 CLI v3**
37
+
:::
35
38
36
39
For extensions defining the latest **Specification Versions 3.0 and higher**, some changes and improvements apply:
37
40
@@ -44,27 +47,28 @@ For extensions defining the latest **Specification Versions 3.0 and higher**, so
44
47
45
48
## Changes to Dependency Configuration
46
49
47
-
!!! info
48
-
✅ The **`ui5.dependencies` package.json configuration** becomes obsolete and is ignored in UI5 CLI v3.
49
-
50
-
Configuration like the following is not needed anymore:
51
-
52
-
```diff title="package.json"
53
-
{
54
-
[...]
55
-
- "ui5": {
56
-
- "dependencies": [
57
-
- "my-package"
58
-
- ]
59
-
- }
60
-
[...]
61
-
}
62
-
```
50
+
::: info
51
+
✅ The **`ui5.dependencies` package.json configuration** becomes obsolete and is ignored in UI5 CLI v3.
52
+
53
+
Configuration like the following is not needed anymore:
54
+
55
+
```diff title="package.json"
56
+
{
57
+
[...]
58
+
- "ui5": {
59
+
- "dependencies": [
60
+
- "my-package"
61
+
- ]
62
+
- }
63
+
[...]
64
+
}
65
+
```
63
66
64
-
`dependencies`, `devDependencies` and `optionalDependencies` are now [automatically analyzed](https://github.com/SAP/ui5-project/blob/ff04ae4aeeb7f7d889dffd0c0e3e8774dd708c79/lib/graph/providers/NodePackageDependencies.js#L104).
65
-
If a dependency can be configured as a UI5 project or UI5 CLI extension, it is added to the graph and its `dependencies` are analyzed.
67
+
`dependencies`, `devDependencies` and `optionalDependencies` are now [automatically analyzed](https://github.com/SAP/ui5-project/blob/ff04ae4aeeb7f7d889dffd0c0e3e8774dd708c79/lib/graph/providers/NodePackageDependencies.js#L104).
68
+
If a dependency can be configured as a UI5 project or UI5 CLI extension, it is added to the graph and its `dependencies` are analyzed.
66
69
67
-
Note that `devDependencies` and `optionalDependencies` are ignored for all but the current root project. For projects that are intended to be consumed in other projects (for example libraries), this means that any required custom tasks must be added to `dependencies`.
70
+
Note that `devDependencies` and `optionalDependencies` are ignored for all but the current root project. For projects that are intended to be consumed in other projects (for example libraries), this means that any required custom tasks must be added to `dependencies`.
71
+
:::
68
72
69
73
## Changes to Module API
70
74
@@ -145,10 +149,11 @@ Especially for projects of type `library`, where standard tasks like [`buildThem
145
149
146
150
In the future, a caching mechanism should help and improve build times with this new behavior.
147
151
148
-
!!! info
149
-
The CLI flags `-a` and `--all` are still present and now an alias for `--include-all-dependencies`. This flag (along with `--include-dependency*` and `--exclude-dependency*`) mainly controls the **build output**. Use it to define whether dependency resources should be part of the build result.
152
+
::: info
153
+
The CLI flags `-a` and `--all` are still present and now an alias for `--include-all-dependencies`. This flag (along with `--include-dependency*` and `--exclude-dependency*`) mainly controls the **build output**. Use it to define whether dependency resources should be part of the build result.
150
154
151
-
Please also refer to the [`ui5 build` documentation](../pages/CLI.md#ui5-build).
155
+
Please also refer to the [`ui5 build` documentation](../pages/CLI.md#ui5-build).
Copy file name to clipboardExpand all lines: packages/documentation/docs/updates/migrate-v4.md
+44-39Lines changed: 44 additions & 39 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,12 +1,13 @@
1
1
# Migrate to v4
2
2
3
-
!!! tip "New Release"
4
-
**UI5 CLI 4.0 has been released on July 24, 2024 🎉**
3
+
::: tip "New Release"
4
+
**UI5 CLI 4.0 has been released on July 24, 2024 🎉**
5
5
6
-
Install the latest version in your projects via: `npm i --save-dev @ui5/cli@latest`
7
-
And update your global install via `npm i --global @ui5/cli@latest`
6
+
Install the latest version in your projects via: `npm i --save-dev @ui5/cli@latest`
7
+
And update your global install via `npm i --global @ui5/cli@latest`
8
8
9
-
And find the announcement blog post here: **[SAP Community: UI5 CLI 4.0](https://community.sap.com/t5/technology-blogs-by-sap/ui5-tooling-4-0/ba-p/13769578)**
9
+
And find the announcement blog post here: **[SAP Community: UI5 CLI 4.0](https://community.sap.com/t5/technology-blogs-by-sap/ui5-tooling-4-0/ba-p/13769578)**
10
+
:::
10
11
11
12
## UI5 2.x Compatibility
12
13
@@ -30,15 +31,16 @@ Old projects might therefore still work, unless they have a non-standard configu
30
31
31
32
## Changes for Projects
32
33
33
-
!!! success "No changes for Specification Versions 2.x and 3.x"
34
-
Projects defining **Specification Version 2.x or 3.x** are expected to be **fully compatible with UI5 CLI v4**
34
+
::: info "No changes for Specification Versions 2.x and 3.x"
35
+
Projects defining **Specification Version 2.x or 3.x** are expected to be **fully compatible with UI5 CLI v4**
35
36
36
-
The following does not apply to them.
37
+
The following does not apply to them.
38
+
:::
37
39
38
40
For projects defining the latest **Specification Version 4.0 or higher**, the following changes apply:
39
41
40
42
***Breaking Change:** Bundling of JavaScript modules requiring "top level scope" as a string is terminated.
41
-
43
+
42
44
In UI5 2.x, the feature of evaluating modules from a string is expected to be removed. Therefore, when using the latest Specification Version, UI5 CLI will **omit affected module from the bundle and log an error message instead.**
43
45
44
46
For more details, see [Builder: JavaScript Files Requiring Top Level Scope](../pages/Builder.md#javascript-files-requiring-top-level-scope).
@@ -78,45 +80,48 @@ Non-public `DuplexCollection#byGlobSource` API has been removed.
78
80
79
81
-**New Option**: Added a new `async` option for `builder.bundles.bundleDefinition.section`.
80
82
81
-
!!! example
82
-
```yaml
83
-
builder:
84
-
bundles:
85
-
- bundleDefinition:
86
-
name: "app.js"
87
-
sections:
88
-
- mode: require
89
-
filters:
90
-
- some/app/Component.js
91
-
resolve: true
92
-
sort: true
93
-
async: true
94
-
```
83
+
::: code-group
84
+
```yaml
85
+
builder:
86
+
bundles:
87
+
- bundleDefinition:
88
+
name: "app.js"
89
+
sections:
90
+
- mode: require
91
+
filters:
92
+
- some/app/Component.js
93
+
resolve: true
94
+
sort: true
95
+
async: true
96
+
```
97
+
:::
95
98
96
99
### Changes to @ui5/project
97
100
98
101
- **Default Workspace Name**: The default `workspaceName` is now `"default"` for API usage.
99
102
100
-
!!! example
101
-
```js
102
-
import {graphFromPackageDependencies} from "@ui5/project/graph";
103
-
104
-
graphFromPackageDependencies({
105
-
/* workspaceName: "default" */
106
-
});
107
-
```
103
+
::: code-group
104
+
```js
105
+
import {graphFromPackageDependencies} from "@ui5/project/graph";
106
+
107
+
graphFromPackageDependencies({
108
+
/* workspaceName: "default" */
109
+
});
110
+
```
111
+
:::
108
112
109
113
- **Directory Naming**: The `ui5HomeDir` has been renamed to `ui5DataDir` in APIs.
110
114
111
-
!!! example
112
-
```js
113
-
import Resolver from "@ui5/project/ui5Framework/Openui5Resolver";
115
+
::: code-group
116
+
```js
117
+
import Resolver from "@ui5/project/ui5Framework/Openui5Resolver";
114
118
115
-
await Resolver.resolveVersion("1.120.15", {
116
-
ui5DataDir: "~/.ui5",
117
-
cwd: process.cwd()
118
-
});
119
-
```
119
+
await Resolver.resolveVersion("1.120.15", {
120
+
ui5DataDir: "~/.ui5",
121
+
cwd: process.cwd()
122
+
});
123
+
```
124
+
:::
120
125
121
126
- **Dependencies**: The `@ui5/builder` is now an optional dependency to the `@ui5/project`
0 commit comments