
Research
2025 Report: Destructive Malware in Open Source Packages
Destructive malware is rising across open source registries, using delays and kill switches to wipe code, break builds, and disrupt CI/CD.
@scrollmeter/react
Advanced tools
React hooks and components for Scrollmeter - A lightweight JavaScript library that visually displays scroll progress on web pages
React hook for Scrollmeter, a lightweight library that visually displays the scroll progress of web pages.
npm install @scrollmeter/react
or
yarn add @scrollmeter/react
In a React environment, use the useScrollmeter hook which provides a targetRef.
import { useScrollmeter } from '@scrollmeter/react'
import '@scrollmeter/core/dist/index.css'
function App() {
const { targetRef } = useScrollmeter<HTMLDivElement>({
useTimeline: true,
useTooltip: true,
usePreview: true,
barOptions: {
color: 'rgba(74, 144, 226, 0.9)',
height: 10,
background: 'rgba(0, 0, 0, 0)',
},
// ... rest of the options ...
})
return <div ref={targetRef}>{/* Your content here */}</div>
}
💡 For Vanilla JavaScript users, please check out @scrollmeter/core package.
import { useScrollmeter, UseScrollmeterOptions } from '@scrollmeter/react'
import '@scrollmeter/core/dist/index.css'
function App() {
const [scrollOptions, setScrollOptions] = useState<UseScrollmeterOptions>({
useTimeline: true,
useTooltip: true,
usePreview: true,
barOptions: {
color: 'rgba(74, 144, 226, 0.9)',
height: 10,
background: 'rgba(0, 0, 0, 0)',
},
timelineOptions: {
color: '#838383',
width: 4,
},
tooltipOptions: {
background: '#333',
fontColor: 'white',
fontSize: 12,
paddingInline: 8,
paddingBlock: 6,
width: 150,
},
})
const { targetRef } = useScrollmeter<HTMLDivElement>(scrollOptions)
return <div ref={targetRef}>{/* Your content here */}</div>
}
| Property | Type | Description | Default |
|---|---|---|---|
| color | string | Progress bar color | rgba(74, 144, 226, 0.9) |
| height | number | Progress bar height | 10 |
| background | string | Progress bar background | rgba(0, 0, 0, 0) |
| Property | Type | Description | Default |
|---|---|---|---|
| color | string | Timeline color | #838383 |
| width | number | Timeline width | 4 |
| Property | Type | Description | Default |
|---|---|---|---|
| background | string | Tooltip background | #333 |
| fontColor | string | Tooltip text color | white |
| fontSize | number | Tooltip font size | 12 |
| paddingInline | number | Tooltip inline padding | 8 |
| paddingBlock | number | Tooltip block padding | 6 |
| width | number | Tooltip width | 150 |
MIT License
Copyright (c) 2024 suhyeon-jeon
FAQs
React hooks and components for Scrollmeter - A lightweight JavaScript library that visually displays scroll progress on web pages
We found that @scrollmeter/react demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 0 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.

Research
Destructive malware is rising across open source registries, using delays and kill switches to wipe code, break builds, and disrupt CI/CD.

Security News
Socket CTO Ahmad Nassri shares practical AI coding techniques, tools, and team workflows, plus what still feels noisy and why shipping remains human-led.

Research
/Security News
A five-month operation turned 27 npm packages into durable hosting for browser-run lures that mimic document-sharing portals and Microsoft sign-in, targeting 25 organizations across manufacturing, industrial automation, plastics, and healthcare for credential theft.