Implemented index.ts for PokemonTypes
This commit is contained in:
parent
93fe0cb24a
commit
1f0ab75d6e
@ -5,7 +5,7 @@ import { Tooltip, Zoom } from '@mui/material';
|
||||
import * as pokeTypeAsset from 'assets/types';
|
||||
import './PokemonTypes.css';
|
||||
|
||||
function findPokeTypeAsset(pokeType: string) {
|
||||
export const findPokeTypeAsset = (pokeType: string) => {
|
||||
switch (pokeType) {
|
||||
case 'normal':
|
||||
return pokeTypeAsset.pokeType_normal;
|
||||
@ -46,7 +46,7 @@ function findPokeTypeAsset(pokeType: string) {
|
||||
default:
|
||||
return pokeTypeAsset.pokeType_normal;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export interface PokemonTypesProps {
|
||||
types: string[];
|
||||
|
2
src/components/PokemonTypes/index.ts
Normal file
2
src/components/PokemonTypes/index.ts
Normal file
@ -0,0 +1,2 @@
|
||||
export * from './PokemonTypes';
|
||||
export { default } from './PokemonTypes';
|
Loading…
x
Reference in New Issue
Block a user