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

Migrate frontend tooling : move from vue-cli to vite #1540

Closed
sbernard31 opened this issue Nov 21, 2023 · 4 comments
Closed

Migrate frontend tooling : move from vue-cli to vite #1540

sbernard31 opened this issue Nov 21, 2023 · 4 comments
Labels
build / ci All about Build or Continious Integration demo Impact our demo (not libraries) housekeeping Refactoring, cleaning code or API

Comments

@sbernard31
Copy link
Contributor

sbernard31 commented Nov 21, 2023

This issue is part of #1492.

Why migrate from vue-cli to vite ?

Vue CLI is in Maintenance Mode!
For new projects, please use create-vue to scaffold Vite-based projects.
(source : https://cli.vuejs.org/)

Also, dependabot seems to report some vulnerability in library used by vue-cli.

Migration

I mainly using :

I did some test in smaller project before :

shared node in monorepo

Our 2 front-end project sharing code from leshan-servers-core-demo.
This shared code is not ever a real json module.
To solve this we need to define custom resolver in vite.config.js and we need to use @rollup/plugin-node-resolve" to explicitily define where is node_modules folder.

@sbernard31 sbernard31 added demo Impact our demo (not libraries) housekeeping Refactoring, cleaning code or API build / ci All about Build or Continious Integration labels Nov 21, 2023
@sbernard31
Copy link
Contributor Author

sbernard31 commented Nov 22, 2023

Build time benefits of the vue-cli => vite migration:

For mvn -f pom.xml clean install javadoc:javadoc -PeclipseJenkins -B command executed on Eclipse Jenkins :

Build Time of Before
(vue-cli)
After
(vite 5)
leshan-server-demo 01:26 min 39.045 s
leshan-bsserver-demo 01:01 min 33.796 s
Full build 08:50 min 07:18 min

For mvn clean install -DskipTests command executed on my local dev machine :

Build Time of Before
(vue-cli)
After
(vite 5)
leshan-server-demo 01:05 min 28.925 s
leshan-bsserver-demo 01:01 min 24.882 s
Full build 03:49 min 02:36 min

(It could improve : https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/issues/3429)

@sbernard31
Copy link
Contributor Author

sbernard31 commented Nov 23, 2023

Still some too big chunk with vite : #1239 (comment)

@sbernard31
Copy link
Contributor Author

Get some little improvement with lighthouse score : #1240 (comment)

@sbernard31
Copy link
Contributor Author

This now integrated in master : #1541

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build / ci All about Build or Continious Integration demo Impact our demo (not libraries) housekeeping Refactoring, cleaning code or API
Projects
None yet
Development

No branches or pull requests

1 participant