chenglou / chenglou/react-motion

Should production build remove/wrap the propTypes with a well known babel-plugin?

Open
#528 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
JavaScript
Stars
21.9k
Forks
1.1k
PR merge metrics
No merged PRs in 30d

Description

This is not a bug, or a big issue, but I'm curious if it's worth adding the **babel-plugin-transform-react-remove-prop-types**, for the production build.
If there's danger that people might reference the propTypes directly, the plugin mentioned above allows wrapping the propTypes code in **process.env.NODE_ENV !== 'production' ? { blabla } : {}**, so that it will not throw.
I see there's a TODO in the Motion.js definition of propTypes, not sure how related it is to this.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.