Installations
npm install react-simple-pull-to-refresh-i
Developer Guide
Typescript
No
Module System
CommonJS
Node Version
16.13.1
NPM Version
8.5.3
Score
32.9
Supply Chain
78.5
Quality
75
Maintenance
100
Vulnerability
100
License
Releases
Unable to fetch releases
Contributors
Unable to fetch Contributors
Languages
TypeScript (52.1%)
JavaScript (34.11%)
CSS (4.97%)
SCSS (4.89%)
HTML (3.92%)
Developer
Download Statistics
Total Downloads
188
Last Day
1
Last Week
2
Last Month
3
Last Year
44
GitHub Statistics
173 Stars
117 Commits
41 Forks
3 Watching
10 Branches
7 Contributors
Package Meta Information
Latest Version
1.3.0
Package Id
react-simple-pull-to-refresh-i@1.3.0
Unpacked Size
7.14 kB
Size
2.73 kB
File Count
3
NPM Version
8.5.3
Node Version
16.13.1
Total Downloads
Cumulative downloads
Total Downloads
188
Last day
0%
1
Compared to previous day
Last week
100%
2
Compared to previous week
Last month
0%
3
Compared to previous month
Last year
-17%
44
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
react-simple-pull-to-refresh
A Simple Pull-To-Refresh Component for React Application with 0 dependency. Works for Mobile and Desktop.
Contributing
⚠️ I don't have much time to take care of the issues at the moment.
🙏 Any help and contribution is greatly appreciated.
Demo
Installation
npm i react-simple-pull-to-refresh
Usage
1import PullToRefresh from 'react-simple-pull-to-refresh';
Pull To Refresh only
1// ... 2 3return ( 4 <PullToRefresh onRefresh={handleRefresh}> 5 <ul> 6 {list.map((item, index) => ( 7 <li key={index}>{item}</li> 8 ))} 9 </ul> 10 </PullToRefresh> 11); 12 13// ...
Pull To Refresh and Fetch More enabled
1// ... 2 3return ( 4 <PullToRefresh onRefresh={handleRefresh} canFetchMore={true} onFetchMore={handleFetchMore}> 5 <ul> 6 {list.map((item, index) => ( 7 <li key={index}>{item}</li> 8 ))} 9 </ul> 10 </PullToRefresh> 11); 12 13// ...
Props Matrix
Name | Type | Required | Default | Description |
---|---|---|---|---|
isPullable | boolean | false | true | Enable or disable pulling feature |
onRefresh | () => Promise | true | Function called when Refresh Event has been trigerred | |
pullDownThreshold | number | false | 67 | Distance in pixel to pull to trigger a Refresh Event |
maxPullDownDistance | number | false | 95 | Maximum transitionY applied to Children when dragging |
resistance | number | false | 1 | Scale of difficulty to pull down |
refreshingContent | JSX.Element or string | false | Content displayed when Pulling or Fetch more has been trigerred | |
pullingContent | JSX.Element or string | false | Content displayed when Pulling | |
canFetchMore | boolean | false | false | Enable or disable fetching more feature |
onFetchMore | () => Promise | false | Function called when Fetch more Event has been trigerred | |
fetchMoreThreshold | number | false | 100 | Distance in pixel from bottom of the container to trigger a Fetch more Event |
backgroundColor | string | false | Apply a backgroundColor | |
className | string | false |
Changelog
1.3.0: Add a resistance prop, that allows to adjust the pull down difficulty - (From: @joshuahiggins)
1.2.5: Fix event listenter leaks - (From: @d-s-x)
1.2.4: Fix overscroll on iOS Safari - (From: @d-s-x)
1.2.3: Add React 17+ as valid peer dependencies - (From: @Felixmosh)
1.2.2: Remove non-null assertion operators from ref.current + TouchEvent check for Mozilla - (From: @HamAndRock)
1.2.1: Remove unnecessary z-index
1.2.0: onRefresh and onFetchMore now require to be of type () => Promise
1.1.2: Bind Scroll event to Window
1.1.0: Check for "canFetchMore" value for each scroll events.
1.1.0: Add a Fetch More feature
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
- Info: project has a license file: LICENCE:0
- Info: FSF or OSI recognized license: MIT License: LICENCE:0
Reason
Found 7/30 approved changesets -- score normalized to 2
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
- Warn: no security policy file detected
- Warn: no security file to analyze
- Warn: no security file to analyze
- Warn: no security file to analyze
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Reason
branch protection not enabled on development/release branches
Details
- Warn: branch protection not enabled for branch 'master'
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
- Warn: 0 commits out of 7 are checked with a SAST tool
Reason
52 existing vulnerabilities detected
Details
- Warn: Project is vulnerable to: GHSA-w8qv-6jwh-64r5
- Warn: Project is vulnerable to: GHSA-257v-vj4p-3w2h
- Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275
- Warn: Project is vulnerable to: GHSA-ff7x-qrg7-qggm
- Warn: Project is vulnerable to: GHSA-43f8-2h32-f4cj
- Warn: Project is vulnerable to: GHSA-rc47-6667-2j5j
- Warn: Project is vulnerable to: GHSA-78xj-cgh5-2h22
- Warn: Project is vulnerable to: GHSA-2p57-rm9w-gvfp
- Warn: Project is vulnerable to: GHSA-7r28-3m3f-r2pr
- Warn: Project is vulnerable to: GHSA-r8j5-h5cx-65gg
- Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h
- Warn: Project is vulnerable to: GHSA-76p3-8jx3-jpfq
- Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3
- Warn: Project is vulnerable to: GHSA-vh95-rmgr-6w4m / GHSA-xvch-5gv4-984h
- Warn: Project is vulnerable to: GHSA-rp65-9cf3-cjxr
- Warn: Project is vulnerable to: GHSA-hj48-42vr-x3v9
- Warn: Project is vulnerable to: GHSA-566m-qj78-rww5
- Warn: Project is vulnerable to: GHSA-7fh5-64p2-3v2j
- Warn: Project is vulnerable to: GHSA-hwj9-h5mp-3pm3
- Warn: Project is vulnerable to: GHSA-p8p7-x288-28g6
- Warn: Project is vulnerable to: GHSA-gcx4-mw62-g8wm
- Warn: Project is vulnerable to: GHSA-7mwh-4pqv-wmr8
- Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw
- Warn: Project is vulnerable to: GHSA-g4rg-993r-mgx7
- Warn: Project is vulnerable to: GHSA-f5x3-32g6-xq36
- Warn: Project is vulnerable to: GHSA-72xf-g2v4-qvf3
- Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92
- Warn: Project is vulnerable to: GHSA-qwcr-r2fm-qrc7
- Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg
- Warn: Project is vulnerable to: GHSA-pxg6-pf52-xh8x
- Warn: Project is vulnerable to: GHSA-gxpj-cx7g-858c
- Warn: Project is vulnerable to: GHSA-ghr5-ch3p-vcr6
- Warn: Project is vulnerable to: GHSA-rv95-896h-c2vc
- Warn: Project is vulnerable to: GHSA-qw6h-vgh9-j6wx
- Warn: Project is vulnerable to: GHSA-jchw-25xp-jwwc
- Warn: Project is vulnerable to: GHSA-cxjh-pqwp-8mfp
- Warn: Project is vulnerable to: GHSA-c7qv-q95q-8v27
- Warn: Project is vulnerable to: GHSA-3rfm-jhwj-7488
- Warn: Project is vulnerable to: GHSA-hhq3-ff78-jv3g
- Warn: Project is vulnerable to: GHSA-29mw-wpgm-hmr9
- Warn: Project is vulnerable to: GHSA-35jh-r3h4-6jhm
- Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv
- Warn: Project is vulnerable to: GHSA-mwcw-c2x4-8c55
- Warn: Project is vulnerable to: GHSA-9wv6-86v2-598j
- Warn: Project is vulnerable to: GHSA-rhx6-c78j-4q9w
- Warn: Project is vulnerable to: GHSA-m6fv-jmcg-4jfg
- Warn: Project is vulnerable to: GHSA-cm22-4g7w-348p
- Warn: Project is vulnerable to: GHSA-hc6q-2mpp-qw7j
- Warn: Project is vulnerable to: GHSA-4vvj-4cpr-p986
- Warn: Project is vulnerable to: GHSA-wr3j-pwj9-hqq6
- Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7
- Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q
Score
2
/10
Last Scanned on 2024-12-16
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More