Data scale in React RangeSelector.
A live React example of jqxRangeSelector, the jQWidgets RangeSelector component, with its complete source code below. It is one of 12 jqxRangeSelector demos for React.
height property – Sets or gets the range selector's height.labelsFormat property – Sets or gets the format of the labels.labelsOnTicks propertymarkersFormat property – Sets or gets the format of the markers.majorTicksInterval property – Sets or gets the interval between major ticks.minorTicksInterval property – Sets or gets the interval between minor ticks.max property – Sets or gets the maximum value of the range selector scale.min property – Sets or gets the minimum value of the range selector scale.range property – An object containing the following properties: from - the start of the initially selected range.theme property – Sets the widget's theme.width property – Sets or gets the range selector's width.To run it in your own app, install the package with npm install jqwidgets-scripts, add these files to a Vite React and TypeScript project, and import jqx.base.css and a theme in main.tsx. Getting started with jqxRangeSelector shows the setup step by step.
import type { JSX } from 'react';
import { useMemo } from 'react';
import JqxRangeSelector from 'jqwidgets-scripts/jqwidgets-react-tsx/jqxrangeselector';
interface DateRange {
from: Date;
to: Date;
}
function App(): JSX.Element {
const min = useMemo(() => new Date(2025, 11, 31), []);
const max = useMemo(() => new Date(2026, 11, 30), []);
const range: DateRange = useMemo(
() => ({ from: new Date(2026, 3, 14), to: new Date(2026, 7, 28) }),
[]
);
return (
<JqxRangeSelector
theme="tailwind-blue-dark"
width="100%"
height={100}
min={min}
max={max}
range={range}
labelsOnTicks={false}
majorTicksInterval="month"
minorTicksInterval="day"
labelsFormat="MMM"
markersFormat="d"
/>
);
}
export default App;