-
Notifications
You must be signed in to change notification settings - Fork 2.7k
MM 18912 Migrate 'utils/filter_users.js' and associated tests to TypeScript #4890
Conversation
utils/filter_users.ts
Outdated
@@ -2,19 +2,22 @@ | |||
// See LICENSE.txt for license information. | |||
import {UserSearchOptions, UserListOptions, UserFilters} from 'utils/constants'; | |||
|
|||
export type FilterOptions = { | |||
[key: string]: string | boolean; | |||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you please include a new-line
here before your comment for linting test to pass
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good, just need to fix the lint error.
I've also added a non-blocking comment.
Thanks @MathewtheCoder!
utils/filter_users.ts
Outdated
@@ -2,19 +2,22 @@ | |||
// See LICENSE.txt for license information. | |||
import {UserSearchOptions, UserListOptions, UserFilters} from 'utils/constants'; | |||
|
|||
export type FilterOptions = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's actually a TypeScript provided type you can use here instead of defining your own dictionary:
Record<string, string | boolean>
This issue has been automatically labelled "stale" because it hasn't had recent activity. /cc @jasonblais @hanzei |
Hey @MathewtheCoder, let us know if you have any questions about feedback from @devinbinnie? We'd be happy to clarify. Thanks for your contribution! :) |
Sorry for not following up with the PR. I will look into the comment and fix the lint error. |
@MathewtheCoder Gentle reminder to fix the merge conflict. |
# Conflicts: # utils/filter_users.test.ts # utils/filter_users.ts
@hanzei Sorry for the slow response. I have fixed the merge conflicts and pushed the changes. |
/update-branch |
Thanks for returning back to this PR @MathewtheCoder 🎉 |
…o MM-20457 * 'master' of github.com:Tak-Iwamoto/mattermost-webapp: Added legal text to upgrade button, and showing again the Edition section in team edition (mattermost#6470) add uiClickPostDropdownMenu (mattermost#6581) Fix nested a tags in Marketplace labels (mattermost#6520) [MM-27277] Enable stream mode for file uploads (mattermost#6568) move cypress plugin api (mattermost#6496) [MM-28361] User limit reached and overage banners for Mattermost Cloud (mattermost#6548) MM-28409 Add e2e for testing archive channel header (mattermost#6522) channel cannot be required (because it's often not there), so check for it (mattermost#6475) Cypress test for MM-T2368 'Fixed width center' setting does not cause scroll pop and breaks post display (mattermost#6443) MM 18912 Migrate 'utils/filter_users.js' and associated tests to TypeScript (mattermost#4890) fix getType is not a function (mattermost#6566) MM-29028 Remove findDOMNode from Slack import (mattermost#6554) MM-28997 Remove references to old context API (mattermost#6545) Add custom slash command tests (mattermost#6391) Cypress/E2E: Fix guest experience ui spec (mattermost#6563) [MM-28784] Migrate string refs to functional ones (mattermost#6494)
Summary
Migrated utils/filter_users.jsx and associate test files to type script
Ticket Link
Fixes mattermost/mattermost#12491
JIRA Link: https://mattermost.atlassian.net/browse/MM-18912