# Bug Report: pages with a custom language emit an invalid, empty \`dir=""\` attribute, with no way to set it

**URL:** <https://forums.realmacsoftware.com/t/bug-report-pages-with-a-custom-language-emit-an-invalid-empty-dir-attribute-with-no-way-to-set-it/57318>\
**Category:** Elements\
**Created:** [August 12, 2026, 6:51pm UTC](https://forums.realmacsoftware.com/t/bug-report-pages-with-a-custom-language-emit-an-invalid-empty-dir-attribute-with-no-way-to-set-it/57318 "2026-08-12T18:51:22Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Fuellemann](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/fuellemann/32/22871_2.png) [@Fuellemann](https://forums.realmacsoftware.com/u/Fuellemann)\
**Post date:** [August 12, 2026, 6:51pm UTC](https://forums.realmacsoftware.com/t/bug-report-pages-with-a-custom-language-emit-an-invalid-empty-dir-attribute-with-no-way-to-set-it/57318/1 "2026-08-12T18:51:22Z")

</div>

When a page’s **Language** popup in the Page Inspector is set to something other than the project language, Elements writes a page attribute `customLanguageDirection` into the project file and leaves it as an **empty string**. `{{page.languageAttributes}}` then expands to:

```html
<html class="scroll-smooth" lang="en" dir="">

```

The `lang` value is correct. The `dir` attribute, however, is emitted with an empty value.  
[bugreport-dir-realmac.md](https://forums.realmacsoftware.com/uploads/short-url/uMUtBteiPRAAp7zLqTTRLl9flFS.md) (12.1 KB)

Please see the attached bug report.

Thank you,  
Jan
