1
0
mirror of https://github.com/SomboChea/ui synced 2024-11-05 14:14:26 +07:00

fix: remove unnecessary ts ignore

This commit is contained in:
Antoine Chalifour 2019-10-03 13:23:38 +02:00 committed by antoinechalifour
parent 852f6eeb22
commit 7a8b158188
4 changed files with 1 additions and 6 deletions

View File

@ -70,7 +70,6 @@ class ActionBar extends Component {
} }
private renderActionBar = ({ packageMeta }) => { private renderActionBar = ({ packageMeta }) => {
// @ts-ignore
const { latest } = packageMeta; const { latest } = packageMeta;
if (!latest) { if (!latest) {

View File

@ -184,7 +184,6 @@ class Header extends Component<Props, State> {
switch (type) { switch (type) {
case 'help': case 'help':
content = ( content = (
// @ts-ignore
<StyledExternalLink blank={true} to={'https://verdaccio.org/docs/en/installation'}> <StyledExternalLink blank={true} to={'https://verdaccio.org/docs/en/installation'}>
<IconButton color={'inherit'}> <IconButton color={'inherit'}>
<Help /> <Help />

View File

@ -65,14 +65,12 @@ export interface Props {
} }
const Icon: React.FC<Props> = ({ className, name, size = 'sm', img = false, pointer = false, ...props }) => { const Icon: React.FC<Props> = ({ className, name, size = 'sm', img = false, pointer = false, ...props }) => {
// @ts-ignore const title = capitalize(name.toString());
const title = capitalize(name);
return img ? ( return img ? (
<ImgWrapper className={className} name={name} pointer={pointer} size={size} title={title} {...props}> <ImgWrapper className={className} name={name} pointer={pointer} size={size} title={title} {...props}>
<Img alt={title} src={Icons[name]} /> <Img alt={title} src={Icons[name]} />
</ImgWrapper> </ImgWrapper>
) : ( ) : (
// @ts-ignore
<Svg className={className} pointer={pointer} size={size} {...props}> <Svg className={className} pointer={pointer} size={size} {...props}>
<title>{title}</title> <title>{title}</title>
<use xlinkHref={`${Icons[name]}#${name}`} /> <use xlinkHref={`${Icons[name]}#${name}`} />

View File

@ -150,7 +150,6 @@ const Package: React.FC<PackageInterface> = ({
}; };
const renderSecondaryComponent = (): React.ReactNode => { const renderSecondaryComponent = (): React.ReactNode => {
// @ts-ignore
const tags = keywords.sort().map((keyword, index) => <Tag key={index}>{keyword}</Tag>); const tags = keywords.sort().map((keyword, index) => <Tag key={index}>{keyword}</Tag>);
return ( return (
<> <>