Hello, we are using ui5 for front-end development. The previous version we used was:
"@ui5/webcomponents": "^1.7.1",
"@ui5/webcomponents-react": "^0.28.0"
Now you want to upgrade to:
"@ui5/webcomponents": "^1.15.0",
"@ui5/webcomponents-react": "^1.17.0".
However, when we upgraded the version to the target version, the following issue occurred.
Since we're using the TS language, it has strong type checking, but the interface to i18nBundle has changed in the updated version. Here is some of the code:
const i18nBundle = useI18nBundle('test');
message = i18nBundle.getText("TEST");
When TS compiles we get the following error:
“Argument of type 'string' is not assignable to parameter of type 'I18nText'.”
After checking the code, we find that in the file i18nBundle.d.ts, the getText method first receives arguments of type I18nText, which should also accept arguments of type string, otherwise the previous TS code will not work after updating the UI5 version.
Please help us solve it, thank you.
Isolated Example
No response
Reproduction steps
1.
2.
3.
...
Expected Behaviour
No response
Screenshots or Videos
UI5 Web Components for React Version
1.17.0
UI5 Web Components Version
1.15.0
Browser
Chrome, Edge, Firefox, Safari
Operating System
No response
Additional Context
No response
Relevant log output
No response
Declaration
[X] I’m not disclosing any internal or sensitive information.
Describe the bug
Hello, we are using ui5 for front-end development. The previous version we used was:
"@ui5/webcomponents": "^1.7.1",
"@ui5/webcomponents-react": "^0.28.0"
Now you want to upgrade to:
"@ui5/webcomponents": "^1.15.0",
"@ui5/webcomponents-react": "^1.17.0".
However, when we upgraded the version to the target version, the following issue occurred.
Since we're using the TS language, it has strong type checking, but the interface to i18nBundle has changed in the updated version. Here is some of the code:
const i18nBundle = useI18nBundle('test');
message = i18nBundle.getText("TEST");
When TS compiles we get the following error:
“Argument of type 'string' is not assignable to parameter of type 'I18nText'.”
After checking the code, we find that in the file i18nBundle.d.ts, the getText method first receives arguments of type I18nText, which should also accept arguments of type string, otherwise the previous TS code will not work after updating the UI5 version.
Please help us solve it, thank you.
Isolated Example
No response
Reproduction steps
1. 2. 3. ...
Expected Behaviour
No response
Screenshots or Videos
UI5 Web Components for React Version
1.17.0
UI5 Web Components Version
1.15.0
Browser
Chrome, Edge, Firefox, Safari
Operating System
No response
Additional Context
No response
Relevant log output
No response
Declaration