Security News
The Risks of Misguided Research in Supply Chain Security
Snyk's use of malicious npm packages for research raises ethical concerns, highlighting risks in public deployment, data exfiltration, and unauthorized testing.
@rentspree/version-check
Advanced tools
Version check component and auto refresh page for React Application!
When deploying a new React Application version, do you still assume all users will refresh to get the new version? Your assumption is right until you find that very user who open the browser for days without refreshing. And when you found it, it already causes you error in your application. So why bother?
This Lib help React application periodically fetch an API server to get its version. It compares the version and execute refresh if a newer version is available!
npm install @rentspree/version-check
The component depend on peerDependencies
for the component dependencies. In order to use the component, you must have those dependencies installed in your main project.
The dependencies are defined in package.json
in peerDependencies
field
Dependency | version | Note |
---|---|---|
prop-types | ^15.5.4 | |
react | ^15.0.0 or ^16.0.0 | |
react-dom | ^15.0.0 or ^16.0.0 | |
styled-components | ^3.3.0 | |
axios | ^0.18.0 |
Simply import the component to your project, and it will be good to go!
import React from "react"
import Version from "@rentspree/version-check"
class App extends React.Component {
render() {
<Version
api="/version"
idleTimeout={10000}
bottom={5}
right={5}
/>
}
}
api
- to be called to get version number (Required)idleTimeout
(number) - idle time before the api is calledcolor
(string) - font colorsize
- font size in pxtop
- absolute position from top in pxright
- absolute position from right in pxbottom
- absolute position from bottom in pxleft
- absolute position from left in pxRentspree © rentspree
FAQs
Component Version for project version check
The npm package @rentspree/version-check receives a total of 24 weekly downloads. As such, @rentspree/version-check popularity was classified as not popular.
We found that @rentspree/version-check demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Snyk's use of malicious npm packages for research raises ethical concerns, highlighting risks in public deployment, data exfiltration, and unauthorized testing.
Research
Security News
Socket researchers found several malicious npm packages typosquatting Chalk and Chokidar, targeting Node.js developers with kill switches and data theft.
Security News
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.