-
Notifications
You must be signed in to change notification settings - Fork 94
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ui5-tooling-transpile] & [ui5-tooling-stringreplace] string replace before transpile don't work #1008
Comments
Hi @MrChuzzle this is a known limitation of the middlewares of the UI5 tooling. Once a middleware handles a resource and sends it back no other middleware will continue to process the resource. Without a bigger change of the UI5 tooling middleware concept, this issue can't be fixed easily. For the tasks this is no problem as there the tasks run always after each other. There is not interruption. I'll see what I can do - but I can't promise a quick solution on that... Cc: @RandomByte @matz3 |
Ah, @MrChuzzle - just noticed one thing - I changed the implementation of the stringreplacer tooling extension a while back to intercept the response and allow to rewrite it. Can you try one thing: exchange the order of the middlewares |
Hi @petermuessig, |
@MrChuzzle - do you run the server with https or http? |
@petermuessig with http |
Ok, thanks - I'll create a small example to verify it and to ensure support in future. I'm still not sure whether I can help without a bigger change in the UI5 tooling |
|
@menof36go - sorry, still no progress here - I need to reserve some time on that but currently there is a pretty busy schedule. |
Hi all,
I used the string replacer to define my app namespace. This works fine with the ui5 module syntax sap.ui.define and Object.extend("namespace.ClassName" {...}). Thanks to ui-tooling-transpile, we can use modern module syntax, now. But when I'm using the transpiler, the string replacer don't work correctly.
I'm using ui5-tooling-transpile version 3.4.1 and ui5-tooling-stringreplace version 3.2.2. and ui5/cli version 3.10.3
My ui5.yaml:
When ui5-tooling-transpiler is used, all *.js files are ignored by the string replacer.
When the string replacer runs after the transpiler, all *.js files getting string replaced correctly, but then the transpiler could not transpile correctly because he transpiled with the placeholders string.
Expected behavior
The string replacer don't ignore the *.js files and replace all placesholders before the files getting transpiled. The result should look like the last screenshot, here.
Screenshots
When the string replacer runs before the transpiler (*.js files are ignored by the string replacer):
When the string replacer runs after the transpiler:
When I remove the string replacer and replace all placesholders with the correct namespace, the transpiler works fine (expected behavior):
Desktop (please complete the following information):
The text was updated successfully, but these errors were encountered: