From 1f0d074caa9f99c31012321f35658d12c4560dc8 Mon Sep 17 00:00:00 2001 From: Tom Xu Date: Mon, 12 Oct 2020 10:59:09 +0800 Subject: [PATCH] refactor(image): improve code (#27087) --- components/image/index.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/image/index.tsx b/components/image/index.tsx index d93624a2f6..3a5973a51e 100644 --- a/components/image/index.tsx +++ b/components/image/index.tsx @@ -1,9 +1,9 @@ import * as React from 'react'; import RcImage, { ImageProps } from 'rc-image'; -import { ConfigConsumerProps, ConfigContext } from '../config-provider'; +import { ConfigContext } from '../config-provider'; const Image: React.FC = ({ prefixCls: customizePrefixCls, ...otherProps }) => { - const { getPrefixCls }: ConfigConsumerProps = React.useContext(ConfigContext); + const { getPrefixCls } = React.useContext(ConfigContext); const prefixCls = getPrefixCls('image', customizePrefixCls); return ; -- GitLab