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

[Feat]: Technical: Translate localization to typescript #1705

Merged
merged 4 commits into from
Feb 9, 2022

Conversation

HeimEndyd
Copy link
Collaborator

No description provided.

Signed-off-by: Daria Terekhova <daria.terekhova@actionengine.com>
Signed-off-by: Maksim Suslov <maksim.suslov@actionengine.com>
Signed-off-by: Maksim Suslov <maksim.suslov@actionengine.com>
@@ -21,7 +21,17 @@
import React from 'react';
import {FormattedMessage} from 'react-intl';

const EnhancedFormattedMessage = props => (
type FormattedMessageType = {
Copy link
Collaborator

Choose a reason for hiding this comment

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

For react components... Replace Type with Props?

Suggested change
type FormattedMessageType = {
type FormattedMessageProps = {

Copy link
Contributor

Choose a reason for hiding this comment

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

agreed, use EnhancedFormattedMessageProps to match the component name

@@ -50,4 +50,7 @@ export const LOCALES = {
* ```
*/

export const LOCALE_CODES = Object.keys(LOCALES).reduce((acc, key) => ({...acc, [key]: key}), {});
export const LOCALE_CODES: {[key: string]: string} = Object.keys(LOCALES).reduce(
Copy link
Contributor

Choose a reason for hiding this comment

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

Add a LocaleCodesType for this constant

Signed-off-by: Maksim Suslov <maksim.suslov@actionengine.com>
@HeimEndyd HeimEndyd merged commit d8d7e44 into master Feb 9, 2022
@delete-merged-branch delete-merged-branch bot deleted the ms/js_to_ts_convertion_localization branch February 9, 2022 10:35
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.

None yet

4 participants