> ## Documentation Index
> Fetch the complete documentation index at: https://ng-primitives.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Slider

<iframe style={{ width: '100%', height: '378px', borderRadius: 12 }} src="https://ng-primitives.github.io/ng-primitives/#/examples/slider" />

## Usage

Assemble the slider directives in your template.

```html
<div ngpSlider></div>
```

## API Reference

The following directives are available to import from the `@ng-primitives/ng-primitives/slider` package:

### NgpSliderDirective

There are no inputs or outputs for this directive.

## Global Configuration

You can configure the default options for all sliders in your application by using the `provideNgpSliderConfig` function in a providers array.

```ts
import { provideNgpSliderConfig } from '@ng-primitives/ng-primitives/slider';

bootstrapApplication(AppComponent, {
  providers: [provideNgpSliderConfig({})],
});
```

### NgpSliderConfig

## Schematics

You can use our schematic to generate a new slider component.

<CodeGroup>
  ```bash Angular CLI
  ng generate @ng-primitives/ng-primitives:slider
  ```

  ```bash Nx
  nx generate @ng-primitives/ng-primitives:slider
  ```
</CodeGroup>

### Options

<ResponseField name="name" type="string">
  The name of the component.
</ResponseField>

<ResponseField name="project" type="string">
  The name of the project to add the component to.
</ResponseField>

<ResponseField name="path" type="string">
  The path to create the component.
</ResponseField>
