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

npm run build hangs forever for Vue3 hello world project when the "Use Babel alongside TypeScript (required for modern mode, auto-detected polyfills, transpiling JSX)" option is checked #7413

Open
nikita-kov-dev opened this issue Aug 6, 2023 · 4 comments

Comments

@nikita-kov-dev
Copy link

nikita-kov-dev commented Aug 6, 2023

Vue version

3.3.4

Link to minimal reproduction

https://github.com/nikitaKov91/vue3-reproduction

Steps to reproduce

  1. Create a project with the following configuration:
    Vue CLI v5.0.8
    ? Please pick a preset: Manually select features
    ? Check the features needed for your project: Babel, TS, Linter, Unit
    ? Choose a version of Vue.js that you want to start the project with 3.x
    ? Use class-style component syntax? Yes
    ? Use Babel alongside TypeScript (required for modern mode, auto-detected
    polyfills, transpiling JSX)? Yes
    ? Pick a linter / formatter config: Airbnb
    ? Pick additional lint features: Lint on save
    ? Pick a unit testing solution: Jest
    ? Where do you prefer placing config for Babel, ESLint, etc.? In dedicated
    config files
    ? Save this as a preset for future projects? No

  2. Run the following command: npm run build

  3. It hangs

What is expected?

The project compiled successfully

What is actually happening?

npm run build hangs

System Info

My OS:
Distributor ID:	Ubuntu
Description:	Ubuntu 22.04.3 LTS
Release:	22.04
Codename:	jammy

vue -V command output:
@vue/cli 5.0.8

node -v command output:
v20.5.0

Any additional comments?

The same configuration but with the "? Use Babel alongside TypeScript (required for modern mode, auto-detected
polyfills, transpiling JSX)? No" option works as expected
No response

@Shyam-Chen
Copy link

vue-class-component

It is no longer recommend to use Class-based components in Vue 3.

@LinusBorg LinusBorg transferred this issue from vuejs/core Aug 7, 2023
@dadoo72
Copy link

dadoo72 commented Sep 20, 2023

Hi, i have a similar issue but only in arch derivatives (endeavour os, manjaro). in debian derivatives as mx-linux it works well.
i made:

  1. sudo npm i -g @vue/cli
  2. vue create myproject
  3. cd myproject
  4. npm run build ----> hangs
    node -v 20.x.x
    npm -v 10.x.x
    vue --version 5.0.8

some help should be very apreciated. thanks

@mensinda
Copy link

mensinda commented Sep 25, 2023

I am also affected by this. I was able to narrow down the problem with docker images (and the minimal test repo from @nikitaKov91):

  • The build works as expected with the node:18.17.1 image, but fails with the node:18.18.0 image.
  • The build works as expected with the node:20.2.0 image, but fails with the node:20.3.0 image.

Steps to reproduce:

  • docker run --rm -it -v $PWD:/mnt node:<major>.<minor> /bin/bash
  • cd /mnt
  • rm -rf node_modules dist
  • npm install
  • npm run build # Either the build finishes fairly quickly or runs forever

@hinaloe
Copy link

hinaloe commented Oct 2, 2023

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

No branches or pull requests

5 participants