Skip to content

Commit

Permalink
Vue cli to Vite migration (#556) (#559)
Browse files Browse the repository at this point in the history
* Vue cli to Vite migration (incomplete)

* Migrated Vue CLI to Vite + all necessary changes

* fix AddressComplete not initialized due to missing script and/or key

* another try to fix addresscomplete

* another try to fix addresscomplete

* testing addresscomplete

* another test for addresscomplete

* revert addresscomplete change

* removed useless dependency

* added blob to content security policy

* changed CSP

* Another attempt to fix CSP

* Fixed pdfjs library + unit tests + removed pdfjs script

* small removals of useless stuff

* updated pdfjs library

* attempting with jsdom

* going back to happy-dom after fixing tests with threads

* Fixed icon + small cleanup in response to comments

* Trying out VITE_ prefix

* Reverting VITE_ to VUE_APP_

* restoring regenerator-runtime dependency

* Removed services package and returned core-js package

* fixed environment prefix issue

* updated business lookup

* added missing keys

* Fixed typo

* Fixed occasional issue arising from baseaddress after changing the import to shared components

* Fixed App and CompleteResolution unit tests

* Fixed some comments after moving from Jest to Vitest

* More jest to vitest fixes

* Fixed Actions unit test + little cleanup

* Changed VITEST_WORKER_ID to VITEST
  • Loading branch information
JazzarKarim authored Aug 8, 2023
1 parent d0e45f2 commit 49772f8
Show file tree
Hide file tree
Showing 63 changed files with 11,032 additions and 32,017 deletions.
4 changes: 4 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
coverage/
dist/
node_modules/
public/
3 changes: 2 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
module.exports = {
root: true,
env: {
node: true
node: true,
es2021: true
},
extends: [
'eslint:recommended',
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ jobs:
- name: Install dependencies
run: |
make setup
- name: Test with Jest
- name: Test with Vitest
id: test
run: |
make test
Expand Down
5 changes: 0 additions & 5 deletions babel.config.js

This file was deleted.

2 changes: 2 additions & 0 deletions devops/cloudbuild-pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@ steps:
- name: node:16.14.2
entrypoint: npm
env:
- 'VUE_APP_ADDRESS_COMPLETE_KEY=$_VUE_APP_ADDRESS_COMPLETE_KEY'
- 'VUE_APP_BUSINESS_CREATE_LD_CLIENT_ID=$_VUE_APP_BUSINESS_CREATE_LD_CLIENT_ID'
- 'VUE_APP_GENESYS_ENV=$_VUE_APP_GENESYS_ENV'
- 'VUE_APP_GENESYS_URL=$_VUE_APP_GENESYS_URL'
- 'VUE_APP_GENESYS_ID=$_VUE_APP_GENESYS_ID'
- 'VUE_APP_REGISTRIES_SEARCH_API_KEY=$_VUE_APP_REGISTRIES_SEARCH_API_KEY'
- 'VUE_APP_WEBCHAT_URL=$_VUE_APP_WEBCHAT_URL'
- 'VUE_APP_WEBCHAT_REASON=$_VUE_APP_WEBCHAT_REASON'
- 'VUE_APP_WEBCHAT_STATUS_URL=$_VUE_APP_WEBCHAT_STATUS_URL'
Expand Down
8 changes: 4 additions & 4 deletions public/index.html → index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<title>BC Business Registry</title>
<link rel="icon" href="<%= BASE_URL %>favicon.png">
<link rel="stylesheet" href="<%= BASE_URL %>css/addresscomplete-2.30.min.css">
<script type="text/javascript" src="<%= BASE_URL %>js/addresscomplete-2.30.min.js" defer></script>
<link rel="icon" href="/favicon.png">
<link rel="stylesheet" href="/css/addresscomplete-2.30.min.css">
<script type="text/javascript" src="/js/addresscomplete-2.30.min.js" defer></script>
</head>
<body>
<noscript>
Expand All @@ -17,6 +17,6 @@
</strong>
</noscript>
<div id="app"></div>
<!-- built files will be auto injected -->
<script type="module" src="/src/main.ts"></script>
</body>
</html>
11 changes: 0 additions & 11 deletions jest.config.js

This file was deleted.

Loading

0 comments on commit 49772f8

Please sign in to comment.