
Security News
Browserslist-rs Gets Major Refactor, Cutting Binary Size by Over 1MB
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
react-carousel3
Advanced tools
A 3D perspective carousel。预览地址:https://xiaxiangfeng.github.io/react-carousel3d/#/carousel
npm i react-carousel3d
Demo:
import React from 'react';
import { Carousel } from 'react-carousel3d';
const style = {
width: 297,
height: 296,
};
export default () => (
<div
style={{
display: 'flex',
justifyContent: 'center',
background: 'linear-gradient(to bottom, #16235e 0%, #020223 100%)',
}}
>
<Carousel height={460} width={980} yOrigin={42} yRadius={48} autoPlay={true}>
<div key={1} style={style}>
<img alt="" src="/image/1.png" />
</div>
<div key={2} style={style}>
<img alt="" src="/image/2.png" />
</div>
<div key={3} style={style}>
<img alt="" src="/image/3.png" />
</div>
<div key={4} style={style}>
<img alt="" src="/image/4.png" />
</div>
<div key={5} style={style}>
<img alt="" src="/image/5.png" />
</div>
<div key={6} style={style}>
<img alt="" src="/image/6.png" />
</div>
</Carousel>
</div>
);
You may pass these options to the carousel constructor. Some of these properties may be changed during runtime via the data handle.
Option | Description | Default |
---|---|---|
height | container height | |
width | container width | |
xOrigin | Center of the carousel (x coordinate) | (container width / 2) |
yOrigin | Center of the carousel (y coordinate) | (container height / 10) |
xRadius | Half the width of the carousel | (container width / 2.3) |
yRadius | Half the height of the carousel | (container height / 6) |
autoPlay | auto play | false |
Install dependencies,
$ npm i
Start the dev server,
$ npm start
Build documentation,
$ npm run docs:build
Run test,
$ npm test
Build library via father
,
$ npm run build
FAQs
react 3d 轮播
The npm package react-carousel3 receives a total of 32 weekly downloads. As such, react-carousel3 popularity was classified as not popular.
We found that react-carousel3 demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Research
Security News
Eight new malicious Firefox extensions impersonate games, steal OAuth tokens, hijack sessions, and exploit browser permissions to spy on users.
Security News
The official Go SDK for the Model Context Protocol is in development, with a stable, production-ready release expected by August 2025.