Skip to content

Convert frontend code to typescript #31559

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

Merged
merged 10 commits into from
Jul 7, 2024
Merged

Convert frontend code to typescript #31559

merged 10 commits into from
Jul 7, 2024

Conversation

silverwind
Copy link
Member

@silverwind silverwind commented Jul 4, 2024

None of the frontend js/ts files was touched besides these two commands (edit: no longer true, I touched one file in 61105d0 because of a deprecation that was not showing before the rename).

tsc currently reports 778 errors, so I have disabled it in CI as planned.

Everything appears to work fine.

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Jul 4, 2024
@silverwind silverwind added the type/refactoring Existing code has been cleaned up. There should be no new functionality. label Jul 4, 2024
@github-actions github-actions bot added modifies/internal modifies/js modifies/dependencies and removed type/refactoring Existing code has been cleaned up. There should be no new functionality. labels Jul 4, 2024
@anbraten
Copy link
Contributor

anbraten commented Jul 4, 2024

Is <script lang="ts"> in .vue files planned for the next step or should it be part of this PR?

@silverwind
Copy link
Member Author

silverwind commented Jul 4, 2024

Is <script lang="ts"> in .vue files planned for the next step or should it be part of this PR?

Ah I wasn't sure about it, thought scripts were already interpreted as typscript and it obviously can import .ts already, but I think it makes sense to add that.

@silverwind
Copy link
Member Author

silverwind commented Jul 4, 2024

Is <script lang="ts"> in .vue files planned for the next step or should it be part of this PR?

Ah I wasn't sure about it, thought scripts were already interpreted as typscript and it obviously can import .ts already, but I think it makes sense to add that.

Fixed in 4f814fb. Initially adding lang produced syntax errors during webpack compile, but it works now that esbuild-loader is set correctly and I tested adding a type annotation which compiled correctly.

@silverwind silverwind force-pushed the ts branch 2 times, most recently from 73ec049 to 6637d71 Compare July 4, 2024 23:58
@GiteaBot GiteaBot added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Jul 5, 2024
@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Jul 7, 2024
@silverwind
Copy link
Member Author

Sorry for all the merge conflicts this will cause 😢.

@silverwind silverwind added the reviewed/wait-merge This pull request is part of the merge queue. It will be merged soon. label Jul 7, 2024
@silverwind silverwind enabled auto-merge (squash) July 7, 2024 15:04
@silverwind silverwind merged commit 5791a73 into go-gitea:main Jul 7, 2024
26 checks passed
@GiteaBot GiteaBot added this to the 1.23.0 milestone Jul 7, 2024
@GiteaBot GiteaBot removed the reviewed/wait-merge This pull request is part of the merge queue. It will be merged soon. label Jul 7, 2024
@silverwind silverwind deleted the ts branch July 7, 2024 18:07
zjjhot added a commit to zjjhot/gitea that referenced this pull request Jul 9, 2024
* giteaofficial/main:
  Use FullName in Emails to address the recipient if possible (go-gitea#31527)
  Don't show hidden labels when filling out an issue template (go-gitea#31576)
  [skip ci] Updated translations via Crowdin
  Convert frontend code to typescript (go-gitea#31559)
  [skip ci] Updated translations via Crowdin
@go-gitea go-gitea locked as resolved and limited conversation to collaborators Oct 5, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. modifies/dependencies modifies/internal modifies/js
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants