Installation
Add Orbit to your project with a package manager or a script tag.
Requirements
Orbit works in every current browser - Chrome, Edge, Firefox and Safari, on desktop and mobile. If you use a package manager you need Node.js 18 or later.
Install the package
bash
npm install orbit-jsbash
yarn add orbit-jsbash
pnpm add orbit-jshtml
<script src="https://cdn.example.com/orbit@2.4.0/orbit.min.js"></script>Using a bundler? Orbit ships as an ES module with types, so Vite, webpack and esbuild tree-shake what you don't use.
Add the styles
Import the base stylesheet once. It sets layout only - slides take your own styles.
js
import 'orbit-js/dist/orbit.css'Check it works
js
import Orbit from 'orbit-js'
console.log(Orbit.version) // "2.4.0"Upgrading from 1.x? Options were renamed in 2.0. Read the changelog before you upgrade.