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

Vue 3 upgrade #551

Open
wants to merge 22 commits into
base: master
Choose a base branch
from
Open

Conversation

stanislawK
Copy link
Contributor

Story / Bug id:

549

Copy link
Member

@w1stler w1stler left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job, just minor comments for now!

frontend/src/plugins/vuetify.js Outdated Show resolved Hide resolved
Copy link
Contributor

@OtisRed OtisRed left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I went mostly through config files and I have more questions than suggestions. However, this is because I obviously need to learn more to be able to contribute again. The amount of work done is nevertheless notable on the first glance so congratulations on handling something like that.

I don't want to hold this PR back until I will be able to review this more properly so I suggest we move onward and I'll catch up retroactively.

However there is one thing that fails at the moment. I wasn't able to log in after populating database. I got POST err everytime I tried one of the users and default password: pass123. Before we go on, probably it would be good to check if that's my bad or is it sth with the code on that side of the page.
Zrzut ekranu 2023-11-22 202601

That being said landing page works like a gold after manual check.

@@ -14,7 +14,7 @@
"prettier/prettier": "error",
"no-unused-vars": ["warn", { "argsIgnorePattern": "^_" }],
"no-multi-spaces": ["error", { "ignoreEOLComments": false }],
"import/no-extraneous-dependencies": ["error"],
"import/no-extraneous-dependencies": ["error", {"devDependencies": true}],
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it a workaround? Not sure how it works exactly but it seems that true is made to ignore this rule [docs here].

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From the documentation you linked, the value Defaults to true It means that there is no change in the logic. I don't remember adding that flag manually (although it is very possible that I forgot that I did it :) ) It is possible that it was added automatically when updating some package.

@@ -1,4 +1,4 @@
FROM node:12
FROM node:19
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's a huge jump :D

@@ -4,5 +4,5 @@ module.exports = {
testMatch: ['**/?(*.)+(spec).js'],
collectCoverage: true,
collectCoverageFrom: ['src/**/*', '!src/assets/**'],
transformIgnorePatterns: ['/node_modules/(?!(vue-scrollactive)/)']
transformIgnorePatterns: ['/node_modules/(?!(vue-scrollactive)/)'],
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason why we are ignoring this? I'm just curious - if the answer is more than 30sec of writing please ignore this :D

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know. But because vue-scrollactive supported was dropped, I ended up rewriting scroll logic to vanilla js. In the newest PR I removed vue-scrollactive, to avoid confusion. Thank you for pointing that out.

import { mount as nativeMount, createLocalVue } from '@vue/test-utils';
import Vuetify from 'vuetify';
import { mount as nativeMount } from '@vue/test-utils';
import { vi } from 'vitest';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do I understand correctly that we are nesting Vitest in Jest? If that's correct (just to get up to speed) why we are doing this? Again - if the answer demands too much let's skip it. I'm just fishing if there's something that should be added in the docs to explain how it works.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are not nesting it, but unfortunately we are using both jest and vitest for now. At some point we need to reconfigure eslint to use vitest, and move all subpackages that are dependent on jest to something different (and most likely reconfigure that too).
Right now we run unittest with vitest, but eslint is configure with jest, as well as some subpackages.
Removing jest is something we should most likely do, but at lest for me it is not a simple task.

Comment on lines +1 to +8
import volontuloImg from '../assets/images/volontulo.png';
import pahImg from '../assets/images/PAH.png';
import alinkaImg from '../assets/images/alinka.png';
import bankEmpatiiImg from '../assets/images/bank_empatii.png';
import streetmixImg from '../assets/images/streetmix.png';
import wysadzUliceImg from '../assets/images/wysadz_ulice.png';
import stronaSpolecznosciImg from '../assets/images/StronaSpolecznosci.png';
import watchDogImg from '../assets/images/watchdog.png';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That seems so much smarter than what I have done with this before :D

@stanislawK
Copy link
Contributor Author

I went mostly through config files and I have more questions than suggestions. However, this is because I obviously need to learn more to be able to contribute again. The amount of work done is nevertheless notable on the first glance so congratulations on handling something like that.

I don't want to hold this PR back until I will be able to review this more properly so I suggest we move onward and I'll catch up retroactively.

However there is one thing that fails at the moment. I wasn't able to log in after populating database. I got POST err everytime I tried one of the users and default password: pass123. Before we go on, probably it would be good to check if that's my bad or is it sth with the code on that side of the page. Zrzut ekranu 2023-11-22 202601

That being said landing page works like a gold after manual check.

@OtisRed are you able to reach backend endpoints with postman? From the error message, it seems that the backend is not running or it is misconfigured.

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

Successfully merging this pull request may close these issues.

3 participants