Skip to content
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

chore: implement SWC #5355

Merged
merged 9 commits into from
Jun 4, 2024
Merged

chore: implement SWC #5355

merged 9 commits into from
Jun 4, 2024

Conversation

aberonni
Copy link
Contributor

@aberonni aberonni commented May 30, 2024

AB#28405

Describe your changes

(Built on top of #5351)

Build faster with swc

Main changes:

  • Moved all code and seed jsons to the src folder. I did not find a way to make swc work without it. These are the majority of the changes files. Stuff I moved This is now separated into chore: move migrations and seed-data into src folder #5357
    • ormconfig
    • seed-data
    • migrations
  • Config files for swc
    • Changes to the package.json npm script to use nest-cli instead of node
    • nest-cli.json: Config file for nest clients, it mainly states to swc
    • .swcrc: Config file for swc. These I had to duplicate the baseUrl and path of tsconfig.
    • Dockerfile install procps to make swc work
  • Code changes.
    • I imlemented the relation solution for our entities as described in the nestjs docs
    • For enums in our dtos I implemented the WrapperType. I do think this workaround suggested by the Nestjs docs is a bit annoying. But since the compile time is so much faster of swc I think it is worth it to use it.
  • Changes have also been applied to the mock-service
  • Changes to deploy scripts
    • I added build to package.json
    • Added build to the workflow files
    • It does work succesfully for test. See run

TODO (from Ruben):

Checklist before requesting a review

  • I have performed a self-review of my code
  • I have added tests wherever relevant
  • I have made sure that all automated checks pass before requesting a review
  • I do not need any deviation from our PR guidelines Please don't merge on my behalf

@aberonni aberonni changed the base branch from main to aberonni/move-migrations-and-seeddata May 30, 2024 09:12
@aberonni aberonni force-pushed the aberonni/move-migrations-and-seeddata branch from c13332b to 4441b4d Compare May 30, 2024 09:16
@aberonni aberonni force-pushed the aberonni/swc branch 4 times, most recently from 64ebce5 to 592a515 Compare May 30, 2024 09:29
@aberonni aberonni force-pushed the aberonni/move-migrations-and-seeddata branch from 4441b4d to e3695ab Compare May 30, 2024 09:38
@aberonni aberonni mentioned this pull request May 30, 2024
4 tasks
@aberonni aberonni force-pushed the aberonni/move-migrations-and-seeddata branch from e3695ab to 36cbaa4 Compare May 30, 2024 11:09
@aberonni aberonni marked this pull request as ready for review May 30, 2024 11:47
@aberonni aberonni force-pushed the aberonni/move-migrations-and-seeddata branch from 36cbaa4 to 7ecb3be Compare May 30, 2024 11:56
@aberonni aberonni force-pushed the aberonni/swc branch 2 times, most recently from 9c302b0 to c2f5737 Compare May 30, 2024 12:03
Vladimir-Petkov
Vladimir-Petkov previously approved these changes Jun 3, 2024
@aberonni aberonni force-pushed the aberonni/move-migrations-and-seeddata branch 2 times, most recently from 01a9ccb to 818f153 Compare June 4, 2024 07:04
Base automatically changed from aberonni/move-migrations-and-seeddata to main June 4, 2024 07:46
@aberonni aberonni dismissed Vladimir-Petkov’s stale review June 4, 2024 07:46

The base branch was changed.

@aberonni aberonni merged commit 131b7cf into main Jun 4, 2024
6 checks passed
@aberonni aberonni deleted the aberonni/swc branch June 4, 2024 07:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

4 participants