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/upgrade deprecated ui packages #236

Open
5 of 13 tasks
loleg opened this issue Dec 8, 2021 · 7 comments
Open
5 of 13 tasks

Migrate/upgrade deprecated ui packages #236

loleg opened this issue Dec 8, 2021 · 7 comments
Assignees
Labels
frontend Pull requests that update Javascript code

Comments

@loleg
Copy link
Contributor

loleg commented Dec 8, 2021

We are having build issues preventing continued development of the frontend, with errors related to several deprecated UI libraries.

The main issue is with node-sass. On the project's GitHub page it says quite clearly that it is no longer actively maintained:

Warning: LibSass and Node Sass are deprecated. While they will continue to receive maintenance releases indefinitely, there are no plans to add additional features or compatibility with any new CSS or Sass features. Projects that still use it should move onto Dart Sass.

Upgrade list

  • Replace node-sass with Dart Sass
  • Upgrade to Popper v2 @popperjs/core
  • Replace vis with github.com/visjs
  • Replace babel-eslint with @babel/eslint-parser
  • Replace vue-headful with vue-meta
  • Look for alternative to vue-headful
  • Upgrade @vue/cli-service
  • Upgrade @vue/cli-plugin-babel
  • Upgrade @vue/cli-plugin-eslint
  • Upgrade @vue/cli-plugin-e2e-cypress
  • Upgrade vuex-persist
  • Upgrade watchpack
  • Upgrade web3 / web3-eth
@loleg loleg changed the title Migrate from node-sass due to deprecation Migrate/upgrade deprecated ui packages Dec 8, 2021
@loleg
Copy link
Contributor Author

loleg commented Dec 8, 2021

As discussed today with @Javany fixing at least the first deprecation this should lift our blockers in CI from current PRs. However, there is still some work required to fix the dozens of SASS warnings.

loleg added a commit to loleg/proxeus-core that referenced this issue Dec 8, 2021
@loleg
Copy link
Contributor Author

loleg commented Dec 8, 2021

Those warnings were just the tip of the iceberg, I am still working on 44 build errors, including this one I'm having a hard time tracking down a fix for:

 error  in ../node_modules/vue-pdf/node_modules/pdfjs-dist/lib/web/pdf_link_service.js

Module parse failed: Unexpected token (341:31)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
|   _cachedPageNumber(pageRef) {
|     const refStr = pageRef.gen === 0 ? `${pageRef.num}R` : `${pageRef.num}R${pageRef.gen}`;
>     return this._pagesRefCache?.[refStr] || null;
|   }
| 

 @ ../node_modules/vue-pdf/src/pdfjsWrapper.js 2:0-69 252:25-39
 @ ../node_modules/cache-loader/dist/cjs.js??ref--13-0!../node_modules/thread-loader/dist/cjs.js!../node_modules/babel-loader/lib!../node_modules/cache-loader/dist/cjs.js??ref--1-0!../node_modules/vue-loader/lib??vue-loader-options!../node_modules/vue-pdf/src/vuePdfNoSss.vue?vue&type=script&lang=js&
 @ ../node_modules/vue-pdf/src/vuePdfNoSss.vue?vue&type=script&lang=js&
 @ ../node_modules/vue-pdf/src/vuePdfNoSss.vue
 @ ../node_modules/cache-loader/dist/cjs.js??ref--13-0!../node_modules/thread-loader/dist/cjs.js!../node_modules/babel-loader/lib!../node_modules/cache-loader/dist/cjs.js??ref--1-0!../node_modules/vue-loader/lib??vue-loader-options!./src/components/document/PdfPreview.vue?vue&type=script&lang=js&
 @ ./src/components/document/PdfPreview.vue?vue&type=script&lang=js&
 @ ./src/components/document/PdfPreview.vue
 @ ../node_modules/cache-loader/dist/cjs.js??ref--13-0!../node_modules/thread-loader/dist/cjs.js!../node_modules/babel-loader/lib!../node_modules/cache-loader/dist/cjs.js??ref--1-0!../node_modules/vue-loader/lib??vue-loader-options!./src/views/DocumentViewer.vue?vue&type=script&lang=js&
 @ ./src/views/DocumentViewer.vue?vue&type=script&lang=js&
 @ ./src/views/DocumentViewer.vue
 @ ./src/router/user.js
 @ ./src/user.js
 @ multi ./src/user.js

Possible solutions discussed here and here. I have already tried adding webpack, babel rules, various versions of the module. I might need to raise an issue in vue-pdf if I don't get any further.

@loleg
Copy link
Contributor Author

loleg commented Dec 9, 2021

The problem above was solved by switching to the standard npm package of vue.pdf. See also webpack instructions.

loleg added a commit that referenced this issue Dec 10, 2021
* Refactored start docs

* Changed source of go-bindata #197

* Updated go dep trackers

* Updated yarn dependencies

* Added update step to Makefile

* New auto-generated bindata tests

* Added doc note about make update

* yarn upgrade

* Doc: rename Infura key as "project ID" for clarity

* Set resource class to medium for CircleCI builds

* Use Debian 'stable' release in Docker

* Add .env configuration loader to make #204

* Copy env during bootstrap

* Documentation related to license finder

* go-bindata install path

* Docker documentation link

* README revised

* Added logging instruction

* Dependency updates, tidy and fix #213

* Documentation tips added

* Yarn update

* Added versioned ssri & is-svg to ui/core

* File type to sync Map #215

* echo-contrib locked to echo v3 #216

* Fix make circular dependency on bindata.go warning

* Switch to CircleCI next gen image #202

* Skip compilation in cloud deploy

* Update to Go 1.16 #217

* Fixed go-bindata install

* Better test for window.web3 #199

* Reverted to legacy CircleCI image

* Revert to new image and new go-bindata load strategy #202

* Fix use of mongo.IndexModel #218

* Update to Node.js LTS 14.x #217

* Improve test for window.web3 #199

* Use same image for build-ui #217

* Updated ui library web3 1.3.4 #199

* Go mod tidy

* Minor ui linting fix

* Go library upgrade: mongo-driver, goja

* Upgrade @vue/cli-service from 3.12.1 to 4.5.12

* Auto-conversion to ES6 syntax #220

* Switch cli to dev dependencies

* Remove eth-lightwallet #220

* Remove vue-append #220

* Update to web3 1.3.5 and sass-loader 10.1.1 #220

* Use go-ethereum v1.9.25 #214

* Revert go-ethereum v1.9.25

* Detect window.ethereum (#203)

* Update docker readme

* Fix settings API keys encryption overwrite

* Ran make all

* Replaced node-sass by sass #236

* Fix SASS division warnings

* vue-cli updated to 4.5.15 & minor delinting

* Added vue-append, core-js; enabled errors shown in ui build

* Vue deep selector syntax

* Added gitpod config, added .env to gitignore, minor mod update

* Updated vue-pdf

* Delinted Document vues

* Ignore all static libs from eslint

* Vue entrypoints delinted

* Views delinted

* Vue entrypoints delinted

* Refactor language list in preview

* Template and PDF Modal views

* Views delinted

* ImexResults delinted/ignored

* Fixed ui issues in testing

Co-authored-by: Mehdy javany <mehdy.javany@gmail.com>
@loleg loleg added the frontend Pull requests that update Javascript code label Dec 15, 2021
@loleg loleg self-assigned this Dec 15, 2021
@loleg
Copy link
Contributor Author

loleg commented Feb 16, 2023

Could this be a link to #292 ?

@loleg
Copy link
Contributor Author

loleg commented Oct 13, 2023

Let's switch to Node 20 first, update the library, see how the project is working. Linked to #366

@loleg
Copy link
Contributor Author

loleg commented Oct 13, 2023

See also #307

@loleg
Copy link
Contributor Author

loleg commented Jan 5, 2024

Progress is being made in #452

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
frontend Pull requests that update Javascript code
Projects
Status: In Progress
Development

No branches or pull requests

2 participants