code refactoring
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
import { atom, selector } from 'recoil'
|
||||
import { RPCResult } from '../types'
|
||||
import { activeDownloadsState } from './downloads'
|
||||
|
||||
export const loadingAtom = atom({
|
||||
@@ -7,11 +6,6 @@ export const loadingAtom = atom({
|
||||
default: true
|
||||
})
|
||||
|
||||
export const optimisticDownloadsState = atom<RPCResult[]>({
|
||||
key: 'optimisticDownloadsState',
|
||||
default: []
|
||||
})
|
||||
|
||||
export const totalDownloadSpeedState = selector<number>({
|
||||
key: 'totalDownloadSpeedState',
|
||||
get: ({ get }) => get(activeDownloadsState)
|
||||
|
||||
Reference in New Issue
Block a user