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 date management from momentjs to dayjs #483

Open
wants to merge 36 commits into
base: main
Choose a base branch
from
Open

Conversation

howard-e
Copy link
Contributor

@howard-e howard-e commented Jan 25, 2023

Due to its size, mutability of the date objects, dropped support and more that can be found here, moving away from moment would be preferred at this time especially since it's footprint is small in the application.

day.js was found to be a widely accepted community alternative.

@howard-e howard-e marked this pull request as ready for review February 9, 2023 17:59
Copy link
Contributor

@evmiguel evmiguel left a comment

Choose a reason for hiding this comment

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

One non-blocking question, but it looks good to me overall!


const issuesResolver = async testPlanReport => {
if (!testPlanReport.candidateStatusReachedAt) return [];

const searchPrefix = `${testPlanReport.at.name} Feedback: "`;
const searchTestPlanVersionTitle =
testPlanReport.testPlanVersion.dataValues.title;
const searchTestPlanVersionDate = moment(
const searchTestPlanVersionDate = dayjs(
Copy link
Contributor

Choose a reason for hiding this comment

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

Non-blocking: Would it be better to use one of the util functions instead of dayjs directly?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Which util functions are you referring to there?

Copy link
Contributor

Choose a reason for hiding this comment

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

Looks like this is the same as convertDateToString

Base automatically changed from update-dependencies to main March 8, 2023 16:53
# Conflicts:
#	.github/workflows/runtest.yml
#	client/components/CandidateTests/CandidateTestPlanRun/index.jsx
#	client/package.json
#	client/tests/TestQueue.test.jsx
#	client/utils/gitUtils.test.js
#	server/package.json
#	yarn.lock
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