Having trouble getting help?
Contact Support
Contact Support
Enable rtl in Angular Switch component
27 Apr 20241 minute to read
Switch component has RTL support. This can be achieved by setting enableRtl
as true
.
The following example illustrates how to enable right-to-left support in Switch component.
import { NgModule } from '@angular/core'
import { BrowserModule } from '@angular/platform-browser'
import { SwitchModule } from '@syncfusion/ej2-angular-buttons'
import { enableRipple } from '@syncfusion/ej2-base'
import { Component } from '@angular/core';
@Component({
imports: [
SwitchModule
],
standalone: true,
selector: 'app-root',
template: `<div class="e-section-control">
<ejs-switch [enableRtl]="true"></ejs-switch></div>`
})
export class AppComponent { }
import { bootstrapApplication } from '@angular/platform-browser';
import { AppComponent } from './app.component';
import 'zone.js';
bootstrapApplication(AppComponent).catch((err) => console.error(err));