Skip to content

Commit

Permalink
Refactor: Remove the index.d.ts file and move its types to the approp…
Browse files Browse the repository at this point in the history
…riate location (#124)

* refactor: move the Cell and Script types to src/models

* refactor: move the Block, CellDep, and Transaction types to src/models

* refactor: move the Address and UDT types to src/models

* refactor: remove unnecessary mocks files

* refactor: move the process of handling the data structure of the chart API response to the fetcher

* refactor: extract the Chart-related types from index.d.ts to a more appropriate location

* refactor: extract some types from index.d.ts to a more appropriate location

* refactor: move State.ChartColor to a more appropriate location

* refactor: use [] instead Array
  • Loading branch information
WhiteMinds authored Oct 25, 2023
1 parent 0d82655 commit 2c7fd6a
Show file tree
Hide file tree
Showing 98 changed files with 1,047 additions and 1,529 deletions.
1 change: 1 addition & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ module.exports = {
allow: ['^.*_'],
},
],
'@typescript-eslint/array-type': 'error',
},
env: {
jest: true,
Expand Down
4 changes: 2 additions & 2 deletions src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { useMemo } from 'react'
import { QueryClient, QueryClientProvider } from 'react-query'
import { ThemeProvider } from 'styled-components'
import { DefaultTheme, ThemeProvider } from 'styled-components'
import Routers from './routes'
import Toast from './components/Toast'
import useInitApp from './contexts/providers/hook'
Expand All @@ -18,7 +18,7 @@ const queryClient = new QueryClient()

const App = () => {
useInitApp()
const theme = useMemo(
const theme = useMemo<DefaultTheme>(
() => ({
primary: getPrimaryColor(),
secondary: getSecondaryColor(),
Expand Down
149 changes: 0 additions & 149 deletions src/__mocks__/block.ts

This file was deleted.

Loading

1 comment on commit 2c7fd6a

@vercel
Copy link

@vercel vercel bot commented on 2c7fd6a Oct 25, 2023

Choose a reason for hiding this comment

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

Please sign in to comment.