logo The World’s #1 Bootstrap 4 HTML, Angular 9, React, VueJS & Laravel
Admin Dashboard Theme

Angular Right-to-Left (RTL)


The RTL does not enabled by default and also the RTL CSS files does not included. You can use the prepared webpack bundler to convert the existing SCSS files into RTL CSS files. You can find the webpack.config.js in each of the Angular demo folder.

Generate RTL CSS

  1. Go to [metronic]/theme/angular/[demo]/ folder.

    cd theme/angular/demo1
  2. Run command to install Angular dependencies and extra webpack plugins for RTL generate.

    npm install
  3. Run npm script command to execute webpack with RTL.

    npm run rtl
  4. You will get the bundle CSS with RTL inside [metronic]/theme/angular/[demo]/src/css/style.angular.rtl.css folder. For Angular RTL to be enabled, this RTL CSS need to be included in the Angular.

  5. Open the Angular config json file from [metronic]/theme/angular/[demo]/angular.json. Change the main SCSS file path to RTL CSS path. Change "src/sass/style.angular.scss" to RTL CSS

  6. Open the Angular index.html file from [metronic]/theme/angular/[demo]/src/index.html. Add the RTL attributes to the HTML tag.

    <html lang="en" direction="rtl" dir="rtl" style="direction: rtl">
  7. Run the Angular as usual using ng serve command.