
Research
/Security News
Critical Vulnerability in NestJS Devtools: Localhost RCE via Sandbox Escape
A flawed sandbox in @nestjs/devtools-integration lets attackers run code on your machine via CSRF, leading to full Remote Code Execution (RCE).
react-marquee-order
Advanced tools
A modern React seamless scroll component with TypeScript support
English | 简体中文
A modern React seamless scrolling component with perfect support for both horizontal and vertical scrolling. Built with TypeScript, featuring smooth scrolling effects, flexible configuration options, and complete type support.
Check out the live demo: React Seamless Scroll Demo
npm install react-marquee-order
# or
pnpm add react-marquee-order
# or
yarn add react-marquee-order
import React, { useRef } from 'react';
import { Marquee, MarqueeHandle } from 'react-marquee-order';
const App = () => {
const marqueeRef = useRef<MarqueeHandle>(null);
const data = [
{ text: "Seamless scroll item 1" },
{ text: "Seamless scroll item 2" },
{ text: "Seamless scroll item 3" }
];
const handleClick = (item: any, index: number) => {
console.log('Clicked:', item, 'at index:', index);
};
return (
<div style={{ width: '100%', height: '40px' }}>
<Marquee
ref={marqueeRef}
loopData={data}
speed={2}
direction="horizontal"
reverse={false}
hoverPause={true}
onClick={handleClick}
/>
</div>
);
};
export default App;
Prop | Type | Default | Description |
---|---|---|---|
loopData | Array<any> | [] | Data array for continuous scrolling |
direction | 'horizontal' | 'vertical' | 'horizontal' | Scroll direction: horizontal/vertical |
speed | number | 2 | Scroll speed (pixels per frame) |
reverse | boolean | false | Whether to scroll in reverse |
hoverPause | boolean | true | Whether to pause on hover |
onClick | (item: any, index: number) => void | - | Callback function for item clicks |
The component exposes these methods via ref:
play()
: Start scrollingpause()
: Pause scrollingreset()
: Reset positionSupports all modern browsers and IE11+ with appropriate polyfills.
Pull requests are welcome to improve this component!
MIT
[2.0.0] - 2024-12-09
FAQs
A modern React seamless scroll component with TypeScript support
The npm package react-marquee-order receives a total of 2 weekly downloads. As such, react-marquee-order popularity was classified as not popular.
We found that react-marquee-order demonstrated a healthy version release cadence and project activity because the last version was released less than 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
/Security News
A flawed sandbox in @nestjs/devtools-integration lets attackers run code on your machine via CSRF, leading to full Remote Code Execution (RCE).
Product
Customize license detection with Socket’s new license overlays: gain control, reduce noise, and handle edge cases with precision.
Product
Socket now supports Rust and Cargo, offering package search for all users and experimental SBOM generation for enterprise projects.