Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on May 20, 2025. It is now read-only.

yashim/fix: ts-eslint warnings #2565

Merged
1 commit merged into from
Jan 26, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/components/hooks/use-debounced-effect.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { useEffect } from 'react'

export const useDebouncedEffect = (effect: () => void, deps: any[], delay: number): void => {
export const useDebouncedEffect = (effect: () => void, deps: unknown[], delay: number): void => {
useEffect(() => {
const handler = setTimeout(() => effect(), delay)

Expand Down
7 changes: 3 additions & 4 deletions src/components/localization/config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import i18n from 'i18next'
import i18n, { use, t } from 'i18next'
import { initReactI18next } from 'react-i18next'
import { str as crc32 } from 'crc-32'
import language_config from '../../../i18n-config'

i18n.use(initReactI18next).init({
use(initReactI18next).init({
ns: ['translations'],
defaultNS: 'translations',

Expand All @@ -25,7 +25,6 @@ i18n.use(initReactI18next).init({

i18n.languages = Object.keys(language_config)

export const localize = (string, values) =>
i18n.t(crc32(string), { defaultValue: string, ...values })
export const localize = (string, values) => t(crc32(string), { defaultValue: string, ...values })

export default i18n
2 changes: 1 addition & 1 deletion src/pages/dmt5/_why-trader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import device from 'themes/device'
type CardContentType = {
header: React.ReactElement
text: React.ReactElement
image: any // Sean declared content as any
image: string
key: number
}

Expand Down
2 changes: 1 addition & 1 deletion src/pages/interim/_love-trading.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ const LeftCTASection = (params: LeftCTASectionProps) => {
}

type RightCTASectionProps = LeftCTASectionProps & {
button_props?: any
button_props?: unknown
}

const RightCTASection = (params: RightCTASectionProps) => {
Expand Down
3 changes: 1 addition & 2 deletions src/pages/p2p/components/_hero.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,8 @@ import { Header, QueryImage, ImageWrapper } from 'components/elements'
import { localize, Localize } from 'components/localization'
import { Background } from 'components/elements/background-image'
import { LinkButton } from 'components/form'
import device from 'themes/device.js'
import device, { size } from 'themes/device.js'
import { useBrowserResize } from 'components/hooks/use-browser-resize'
import { size } from 'themes/device'

const BackgroundWrapper = styled(Background)`
height: 100%;
Expand Down
4 changes: 2 additions & 2 deletions src/store/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@ type DerivProviderProps = {

type WebsiteStatusType = {
clients_country: string
crypto_config: any
crypto_config: unknown
}

export type DerivStoreType = {
academy_data: AcademyDataType
crypto_config: any
crypto_config: unknown
is_eu_country: boolean
is_livechat_interactive: boolean
is_loading_lc: boolean
Expand Down