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

Feature/#230 experience and studies sorted by date #234

Conversation

migalko94
Copy link
Collaborator

No description provided.

@@ -0,0 +1,15 @@
import { ExperienceVm } from './experience-section.vm';
import { dateExtractor, sortByDate } from '../../helpers';
Copy link
Member

Choose a reason for hiding this comment

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

Use '@/helpers' on import and move it at first line

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

With import in this way I get test failures

export const mapSortedRolesIntoExperience = (experience: ExperienceVm[]): ExperienceVm[] =>
experience.map(experienceItem => sortRolesByDate(experienceItem));

export const sortExperienceByDate = (experience: ExperienceVm[]): ExperienceVm[] =>
Copy link
Member

Choose a reason for hiding this comment

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

What's the difference between sortExperienceByDate and sortByDate functions?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

In sortExperienceByDate, specifies that the sorting is performed on the first element of the array as a parameter of dateExtractor

@@ -1,6 +1,7 @@
import { ManfredAwesomicCV } from '../../model';
Copy link
Member

Choose a reason for hiding this comment

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

Use '@/model'

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Changed

@@ -0,0 +1,5 @@
import { sortByDate } from '../../helpers';
Copy link
Member

Choose a reason for hiding this comment

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

Use '@/helpers"

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Same as with experience. With import in this way I get test failures

@migalko94
Copy link
Collaborator Author

Added missing typing on 'b' in sortExperienceByDate function

@juanpms2 juanpms2 closed this Oct 24, 2023
@migalko94 migalko94 deleted the feature/#230-experience-and-studies-sorted-by-date branch October 24, 2023 16:31
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.

2 participants