Skip to content

fix(project): Allow Component.ts#1243

Merged
maxreichmann merged 6 commits intomainfrom
fix/allow-component.ts
Dec 15, 2025
Merged

fix(project): Allow Component.ts#1243
maxreichmann merged 6 commits intomainfrom
fix/allow-component.ts

Conversation

@maxreichmann
Copy link
Copy Markdown
Member

Fixes #1242.
This allows the use of TS for Component files.

@coveralls
Copy link
Copy Markdown

coveralls commented Dec 11, 2025

Coverage Status

coverage: 94.691% (-0.01%) from 94.703%
when pulling 4e971cd on fix/allow-component.ts
into 2a84111 on main.

@maxreichmann maxreichmann force-pushed the fix/allow-component.ts branch from 222220f to 85f7366 Compare December 11, 2025 15:30
@maxreichmann maxreichmann marked this pull request as ready for review December 11, 2025 15:46
// or if both are present
const componentJSResource = await this._getRawSourceReader().byPath("/Component.js");
const componentTSResource = await this._getRawSourceReader().byPath("/Component.ts");
if (componentJSResource && componentTSResource) {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would expect this to be a real use case, where the output dir is the same as source dir.

In such case, IMO we should check only the TS file as it must be the source for the JS.

Let the others say what do they think about it

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree, I think it should ne fine if both are present. We only want to ensure that at least one Component file exists

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done in 1f661f3

@d3xter666 d3xter666 requested a review from a team December 12, 2025 12:21
RandomByte
RandomByte previously approved these changes Dec 12, 2025
Copy link
Copy Markdown
Member

@RandomByte RandomByte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🤝

Comment on lines +294 to +295
// Throw if neither Component.js nor Component.ts is present
// or if both are present
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This comment seems outdated now

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@maxreichmann maxreichmann merged commit 3b8ce29 into main Dec 15, 2025
30 checks passed
@maxreichmann maxreichmann deleted the fix/allow-component.ts branch December 15, 2025 09:02
d3xter666 pushed a commit that referenced this pull request Dec 15, 2025
🚜 New release prepared
---


<details><summary>builder: 5.0.0-alpha.2</summary>

##
[5.0.0-alpha.2](builder-v5.0.0-alpha.1...builder-v5.0.0-alpha.2)
(2025-12-15)


### chore

* **builder:** Synchronize ui5-cli-packages versions


### Dependencies

* The following workspace dependencies were updated
  * dependencies
    * @ui5/fs bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
    * @ui5/logger bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
  * devDependencies
    * @ui5/project bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
</details>

<details><summary>cli: 5.0.0-alpha.2</summary>

##
[5.0.0-alpha.2](cli-v5.0.0-alpha.1...cli-v5.0.0-alpha.2)
(2025-12-15)


### chore

* **cli:** Synchronize ui5-cli-packages versions


### Dependencies

* The following workspace dependencies were updated
  * dependencies
    * @ui5/builder bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
    * @ui5/fs bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
    * @ui5/logger bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
    * @ui5/project bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
    * @ui5/server bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
</details>

<details><summary>fs: 5.0.0-alpha.2</summary>

##
[5.0.0-alpha.2](fs-v5.0.0-alpha.1...fs-v5.0.0-alpha.2)
(2025-12-15)


### chore

* **fs:** Synchronize ui5-cli-packages versions


### Dependencies

* The following workspace dependencies were updated
  * dependencies
    * @ui5/logger bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
</details>

<details><summary>logger: 5.0.0-alpha.2</summary>

##
[5.0.0-alpha.2](logger-v5.0.0-alpha.1...logger-v5.0.0-alpha.2)
(2025-12-15)


### chore

* **logger:** Synchronize ui5-cli-packages versions
</details>

<details><summary>project: 5.0.0-alpha.2</summary>

##
[5.0.0-alpha.2](project-v5.0.0-alpha.1...project-v5.0.0-alpha.2)
(2025-12-15)


### Bug Fixes

* **project:** Allow Component.ts
([#1243](#1243))
([3b8ce29](3b8ce29))


### Dependencies

* The following workspace dependencies were updated
  * dependencies
    * @ui5/fs bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
    * @ui5/logger bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
  * peerDependencies
    * @ui5/builder bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
</details>

<details><summary>server: 5.0.0-alpha.2</summary>

##
[5.0.0-alpha.2](server-v5.0.0-alpha.1...server-v5.0.0-alpha.2)
(2025-12-15)


### chore

* **server:** Synchronize ui5-cli-packages versions


### Dependencies

* The following workspace dependencies were updated
  * dependencies
    * @ui5/builder bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
    * @ui5/fs bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
    * @ui5/logger bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
  * devDependencies
    * @ui5/project bumped from ^5.0.0-alpha.1 to ^5.0.0-alpha.2
</details>

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[v5/next] Serving a component type project written in TypeScript fails

4 participants