{"id":16180560,"url":"https://github.com/pstachula-dev/react-micro-carousel","last_synced_at":"2026-03-05T09:01:41.070Z","repository":{"id":247144905,"uuid":"816435402","full_name":"pstachula-dev/react-micro-carousel","owner":"pstachula-dev","description":"React micro carousel","archived":false,"fork":false,"pushed_at":"2025-03-24T08:42:15.000Z","size":3112,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-11T05:36:35.119Z","etag":null,"topics":["carousel","carousel-component","carousel-slider","headless","nextjs","react","react-components","reactjs","slider","tailwindcss"],"latest_commit_sha":null,"homepage":"https://simple-headless-carousel.onrender.com/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pstachula-dev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-06-17T18:42:30.000Z","updated_at":"2025-03-24T10:13:32.000Z","dependencies_parsed_at":"2024-08-23T10:25:27.999Z","dependency_job_id":"5d3024b9-a362-43e1-9c30-6dfffcbdf604","html_url":"https://github.com/pstachula-dev/react-micro-carousel","commit_stats":null,"previous_names":["pstachula-dev/simple-headless-carousel","pstachula-dev/react-micro-carousel"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/pstachula-dev/react-micro-carousel","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pstachula-dev%2Freact-micro-carousel","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pstachula-dev%2Freact-micro-carousel/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pstachula-dev%2Freact-micro-carousel/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pstachula-dev%2Freact-micro-carousel/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pstachula-dev","download_url":"https://codeload.github.com/pstachula-dev/react-micro-carousel/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pstachula-dev%2Freact-micro-carousel/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30117478,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-05T08:19:04.902Z","status":"ssl_error","status_checked_at":"2026-03-05T08:17:37.148Z","response_time":93,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["carousel","carousel-component","carousel-slider","headless","nextjs","react","react-components","reactjs","slider","tailwindcss"],"created_at":"2024-10-10T06:06:17.948Z","updated_at":"2026-03-05T09:01:41.049Z","avatar_url":"https://github.com/pstachula-dev.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# React Micro Carousel\n\n![example workflow](https://github.com/pstachula-dev/react-micro-carousel/actions/workflows/main.yml/badge.svg)\n![bundlesize](https://badgen.net/bundlephobia/minzip/react-micro-carousel)\n![NPM Version](https://img.shields.io/npm/v/react-micro-carousel)\n![GitHub License](https://img.shields.io/github/license/pstachula-dev/react-micro-carousel)\n\n## Links\n\n- [Examples \u0026 Documentation](https://simple-headless-carousel.onrender.com/)\n- [NPM](https://www.npmjs.com/package/react-micro-carousel)\n\n## Features\n\n- Extremely small package size (gzipped):\n  - Javascript: 2.6kB\n  - CSS: 1.5kB\n- 0 external dependencies\n- Full typescript support\n- Built in with Tailwind, but you can always customize the styles\n- Handling touch/mouse events\n- Lazy image loading\n- Responsive support\n\n## How to use\n\n### Main Tailwind 4.x:\n\n`globals.css`\n\n```css\n@source \"../node_modules/react-micro-carousel/dist\";\n```\n\n### Legacy Tailwind 3.x:\n\n`tailwind.config.ts`\n\n```js\nexport default {\n  content: [\n    \"./src/**/*.{js,ts,jsx,tsx}\",\n    \"./node_modules/react-micro-carousel/**/*.js\",\n  ],\n} satisfies Config;\n```\n\n### Vanilla css (prebuild for Tailwind 4)\n\n```js\nimport 'react-micro-carousel/styles.min.css';\n```\n\n### Components markup\n\n```js\nimport {\n  Carousel,\n  CarouselProvider,\n  Counter,\n  DotsGroup,\n  NextButton,\n  PrevButton,\n  Slide,\n} from 'react-micro-carousel';\n\n\u003cCarouselProvider slideHeight={200} total={2}\u003e\n  \u003cCarousel\u003e\n    \u003cSlide index={0}\u003e\n      \u003cimg src=\"...\" /\u003e\n    \u003c/Slide\u003e\n    \u003cSlide index={1}\u003e\n      \u003cimg src=\"...\" /\u003e\n    \u003c/Slide\u003e\n  \u003c/Carousel\u003e\n\n  \u003cDotsGroup /\u003e\n  \u003cNextButton\u003eNext\u003c/NextButton\u003e\n  \u003cPrevButton\u003ePrev\u003c/PrevButton\u003e\n\u003c/CarouselProvider\u003e;\n```\n\n## Props documentation\n\n### `\u003cCarouselProvider /\u003e`\n\nComponent is used to initialize the carousel context with configuration options and wrap the other components.\n\n| Prop          | Type      | Default | Required |\n| ------------- | --------- | ------- | -------- |\n| children      | ReactNode |         | Yes      |\n| slideHeight   | number    | 0       | Yes      |\n| total         | number    | 0       | Yes      |\n| autoPlayDelay | number    | false   | No       |\n| slidesVisible | number    | 1       | No       |\n| step          | number    | 1       | No       |\n| threshold     | number    | 0.25    | No       |\n| infinite      | boolean   | false   | No       |\n| disableTouch  | boolean   | false   | No       |\n| lazy          | boolean   | true    | No       |\n| autoPlay      | boolean   | false   | No       |\n\n### `\u003cCarousel /\u003e`\n\nA carousel that wraps the slides and provides the core functionality, such as scrolling to the next or previous slide.\n\n| Prop              | Type      | Default | Required |\n| ----------------- | --------- | ------- | -------- |\n| children          | ReactNode |         | Yes      |\n| wrapperClassName  | string    |         | No       |\n| carouselClassName | string    |         | No       |\n\n### `\u003cSlide /\u003e`\n\nA single slide in a carousel.\n\n| Prop      | Type      | Default | Required |\n| --------- | --------- | ------- | -------- |\n| children  | ReactNode |         | Yes      |\n| index     | number    |         | Yes      |\n| className | string    |         | No       |\n\n### `\u003cDot /\u003e`\n\nA single dot.\n\n| Prop          | Type     | Default | Required |\n| ------------- | -------- | ------- | -------- |\n| className     | string   |         | No       |\n| colorActive   | string   |         | No       |\n| colorInactive | string   |         | No       |\n| index         | number   |         | Yes      |\n| disabled      | boolean  |         | No       |\n| onClick       | Function |         | No       |\n\n### `\u003cDotsGroup /\u003e`\n\nA component that renders a group of dots, representing the slides in the carousel.\nIt provides auto generated dots for the carousel.\n\n| Prop          | Type     | Default | Required |\n| ------------- | -------- | ------- | -------- |\n| className     | string   |         | No       |\n| dotClassName  | string   |         | No       |\n| colorActive   | string   |         | No       |\n| colorInactive | string   |         | No       |\n| onClick       | Function |         | No       |\n\n### `\u003cNextButton /\u003e`\n\n| Prop      | Type      | Default | Required |\n| --------- | --------- | ------- | -------- |\n| className | string    |         | No       |\n| children  | ReactNode |         | Yes      |\n| onClick   | Function  |         | No       |\n\n### `\u003cPrevButton /\u003e`\n\n| Prop      | Type      | Default | Required |\n| --------- | --------- | ------- | -------- |\n| className | string    |         | No       |\n| children  | ReactNode |         | Yes      |\n| onClick   | Function  |         | No       |\n\n### `\u003cCounter /\u003e`\n\n| Prop      | Type   | Default | Required |\n| --------- | ------ | ------- | -------- |\n| className | string |         | No       |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpstachula-dev%2Freact-micro-carousel","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpstachula-dev%2Freact-micro-carousel","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpstachula-dev%2Freact-micro-carousel/lists"}