Skip to main content

Circular

The circular option connects the first and last panels to enable infinite loop navigation. Moving next from the last panel goes to the first panel, and moving previous from the first panel goes to the last panel.

import Flicking from "@egjs/flicking";
import "@egjs/flicking/dist/flicking.css";
import "./styles.css";

// circular: false (default)
new Flicking("#flick-normal", {
  circular: false,
  align: "center"
});

// circular: true (infinite loop)
new Flicking("#flick-circular", {
  circular: true,
  align: "center"
});

Summary

Key Options

OptionTypeDefaultDescription
circularbooleanfalseEnable infinite loop mode
circularFallback"linear" | "bound""linear"Fallback behavior when circular cannot be activated

Comparison by Value

ValueBehaviorSuitable For
falseCannot move beyond the first/last panelFinite content, UI with clear start/end
trueFirst and last panels are connected for infinite navigationCarousels, galleries, continuous browsing

Details

circular: false in Detail

This is the default. You cannot move previous from the first panel or next from the last panel. Suitable for displaying finite content.

circular: true in Detail

The first and last panels are internally connected. Users can scroll continuously in either direction. Panels are not duplicated; instead, their positions are recalculated to create a seamless connection.

circularFallback in Detail

Specifies the fallback behavior when circular: true but the activation conditions are not met:

  • "linear": Operates in normal mode (stops at first/last)
  • "bound": Operates in bound mode (bounces at boundaries)
  • Relationship with bound: When circular: true and bound: true are set together, circular takes priority. bound is ignored.
  • Relationship with align: The combination of circular: true + align: "center" is the most common carousel pattern.
  • Relationship with panelsPerView: Setting panelsPerView affects the total panel size calculation, which can influence the circular activation condition.

Use Cases

When to use?
  • circular: true: Image galleries, product carousels, banner sliders, seamless browsing
  • circular: false: Onboarding screens, step-by-step wizards, content with clear start/end

Notes

Activation condition

Circular mode is only activated when total panel size >= viewport size. If the condition is not met, it automatically falls back to the mode specified in circularFallback.

Cannot be used with bound

circular: true and bound: true are mutually exclusive. If both are true, circular takes priority and bound is ignored.

  • bound: Boundary restriction mode (mutually exclusive with circular)
  • align: Panel alignment method
  • Alignment: Alignment options with circular combination
  • Bound: Boundary restriction mode