Skip to content

Commit

Permalink
chore: add @rc-component/father-plugin (#341)
Browse files Browse the repository at this point in the history
* chore: add @rc-component/father-plugin

* remove displayName when production
  • Loading branch information
afc163 committed May 4, 2024
1 parent 9bc5241 commit 443d90e
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
7 changes: 1 addition & 6 deletions .fatherrc.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
import { defineConfig } from 'father';

export default defineConfig({
platform: 'browser',
cjs: { output: 'lib' },
esm: {
output: 'es',
alias: { 'rc-util/lib': 'rc-util/es' },
},
plugins: ['@rc-component/father-plugin'],
});
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@
},
"devDependencies": {
"@ant-design/icons": "^5.0.1",
"@rc-component/father-plugin": "^1.0.2",
"@testing-library/jest-dom": "^6.4.0",
"@testing-library/react": "^15.0.6",
"@types/classnames": "^2.2.10",
Expand Down
4 changes: 3 additions & 1 deletion src/Image.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,8 @@ const ImageInternal: CompoundedComponent<ImageProps> = props => {

ImageInternal.PreviewGroup = PreviewGroup;

ImageInternal.displayName = 'Image';
if (process.env.NODE_ENV !== 'production') {
ImageInternal.displayName = 'Image';
}

export default ImageInternal;

0 comments on commit 443d90e

Please sign in to comment.