Akryum / Akryum/guijs

Vue CLI & Babel

Open
#116 0 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Vue
Stars
1.3k
Forks
41
PR merge metrics
No merged PRs in 30d

Description

**Describe the bug**
I had not upgraded my VueCLI with the Babel presets because I had forgotten and was getting strange errors. For those who are unfamilliar with Babel and the plugin for the VueCLI, or who have never set up this sort of software before, it might be usedful to improve the automation script, or reference these steps... because the errors were deep in the node modules directories like:

```sh

ERROR Failed to compile with 6 errors 2:21:53 PM

These dependencies were not found:

* core-js/modules/es.error.cause.js in /monorepos/tauri/guijs/node_modules/@vue/cli-plugin-babel/node_modules/cache-loader/dist/cjs.js??ref--12-0!/monorepos/tauri/guijs/node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib!/monorepos/tauri/guijs/node_modules/cache-loader/dist/cjs.js??ref--0-0!/monorepos/tauri/guijs/node_modules/vue-loader/lib??vue-loader-options!/monorepos/tauri/guijs/node_modules/@guijs/frontend-ui/components/Error.vue?vue&type=script&lang=js&
```

The steps below are the exact steps I needed in order to get the front-end functional with the backend on Ubuntu Bionic in a Fish environment.

**To Fix it I had to...**
```fish
# from anywhere
yarn global add @vue/cli

# from ./ directory relative path
yarn run autoinstall;
cd ./packages/@guijs/frontend-core/; vue upgrade babel;
pushd . ; cd ./packages/@guijs/native-dialog/ ; yarn; yarn install; yarn build; popd ;
pushd . ; cd ./packages/@guijs/get-workspaces/ ; yarn; yarn install; yarn build; popd ;
pushd . ; cd ./packages/@guijs/server-core/ ; yarn; yarn install; yarn build; yarn dev; popd ;
cd monorepos/tauri/guijs/node_modules/@vue/cli-plugin-babel/; yarn install;
cd monorepos/tauri/guijs/node_modules/@vue/cli-plugin-babel/node_modules/core-js; npm install;
cd /monorepos/tauri/guijs/node_modules/core-js; npm install;
cd /monorepos/tauri/guijs/node_modules/fbjs/node_modules/core-js; npm install;
cd /monorepos/tauri/guijs/; yarn install; yarn autoinstall;
pushd . ; cd ./packages/@guijs/frontend-core/; yarn; yarn install; yarn serve; popd ;
```

**Additional context**
This happened in a VM on Ubuntu Bionic using Fish 3.3.1+. Node 14+

Hope this helps somebody!

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.