question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Is your feature request related to a problem? Please describe. I am currently trying to run the library on react-native-web. I know that the library is not officially supported on web, but would be nice to make it work. I will be doing some changes on my own fork, but wanted to use this thread as a platform to discuss a few things.

react-native-web has unspoorted ViewPropTypes as of 0.12. Therefore, I get the following error:

Popover.tsx?f681:1 Uncaught TypeError: Cannot read property 'style' of undefined

Caused by the following lines:

popoverStyle: ViewPropTypes.style,
arrowStyle: ViewPropTypes.style,
backgroundStyle: ViewPropTypes.style,

Describe the solution you’d like First I want to ask you why is PropTypes used in this repo while there is already great TypeScript implementation. If we get rid of PropTypes, it will work on react-native-web too. I will work on further improvements to make this library work on web, but I think it would be the first step.

I would be happy if you could inform me why you choose to opt in for PropTypes.

Thanks in advance!

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:12 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
SteffeyDevcommented, Oct 23, 2020

Ah very cool, I’ll add this in and see if it works

0reactions
SteffeyDevcommented, Oct 24, 2020

Ok, this is done in the latest release, thanks for finding a good solution!

Read more comments on GitHub >

github_iconTop Results From Across the Web

babel-plugin-transform-react-remove-prop-types - npm
Remove unnecessary React propTypes from the production build. Latest version: 0.4.24, last published: 4 years ago.
Read more >
babel-plugin-transform-react-remove-prop-types - GitHub
The problem solved. Remove React propTypes from the production build, as they are only used in development. You can save bandwidth by removing...
Read more >
How to remove React PropTypes from production rollup build?
I want to remove prop types from prod builds in the IIFE build. The babel-plugin-transform-react-remove-prop-types removes the prop types ...
Read more >
Removing propTypes on Production > React with Symfony
This is a Babel plugin that can remove propTypes. Copy the library name, find your terminal, and get it!
Read more >
babel-plugin-react-remove-prop-types - Yarn
Babel Plugin for removing React propTypes. Circle CI Downloads. Removes propTypes from your React components. This plugin deprecated.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found