Documentation v8.1.9

RTL Version

Right to Left (RTL) version of Metronic Laravel  can be easily setup with special Laravel Mix plugin that depends on RTLCSS  tools.

  1. Find the webpack.mix.js file.
  2. Uncomment this part of the code in the webpack.mix.js file.
    new WebpackRTLPlugin({
        filename: '[name].rtl.css',
        options: {},
        plugins: [],
    })
  3. Run the build command for Laravel.
    npm run dev --rtl --demo1
  4. You will find the RTL CSS files in the public folder. Here is the list of CSS files that need to include in the HTML:
    • public/[demo]/css/style.bundle.rtl.css
    • public/[demo]/plugins/global/plugins.bundle.rtl.css
  5. Change the CSS files reference in config/demo1/general.php
    'assets'  => array(
        // ...
        'css'     => array(
            'plugins/global/plugins.bundle.rtl.css',
            'css/style.bundle.rt.css',
        ),
        // ...
    ),
  6. Edit app/helpers.php to force enable RTL option.
    function isRTL()
    {
        return true;
    }
    This option will append these attributes to the HTML tag.
    <html lang="en" dir="rtl" direction="rtl" style="direction:rtl;" >