Page MenuHomePhabricator

Server: Look up language directionality based on code
Closed, ResolvedPublic

Description

Something like https://github.com/shadiabuhilal/rtl-detect may be sufficient for the backend.

Event Timeline

I did not find any existing API to do this. I looked through https://www.wikidata.org/w/api.php and https://www.wikidata.org/w/api.php?action=help&modules=query.

In the frontend, ULS can provide the language directionality, $.uls.data.getDir( languageCode ) see e.g. https://github.com/wikimedia/mediawiki-extensions-Wikibase/blob/master/lib/resources/wikibase.Site.js#L115.

Something like https://github.com/shadiabuhilal/rtl-detect may be sufficient for the backend.

Pablo-WMDE renamed this task from Look up language directionality based on code to Server: Look up language directionality based on code.Nov 26 2018, 2:22 PM