Stop propagation body scroll
Auto find children nodes with css property (overflow || overflow-x || overflow-y) and allow native scrolling
https://docccdev.github.io/react-overflow-scrolling/
$ npm i react-overflow-scrolling --save
CSS
.overflow-scrolling {
overflow: auto;
-webkit-overflow-scrolling: touch;
}
JSX
import OverflowScrolling from 'react-overflow-scrolling';
export class ExampleOverflowScrolling extends React.Component {
render() {
return (
<OverflowScrolling className='overflow-scrolling'>
...
</OverflowScrolling>
);
}
}