13 lines
488 B
JavaScript
13 lines
488 B
JavaScript
import { getWindow } from './dom/getWindow';
|
|
export function initializeDir(win) {
|
|
var w = (win || getWindow());
|
|
if (w && !w.__hasInitializedDir__) {
|
|
w.__hasInitializedDir__ = true;
|
|
// Ensure that the documentElement has a 'dir' attribute.
|
|
var documentElement = w.document.documentElement;
|
|
if (!documentElement.hasAttribute('dir')) {
|
|
documentElement.setAttribute('dir', 'ltr');
|
|
}
|
|
}
|
|
}
|
|
//# sourceMappingURL=initializeDir.js.map
|