Skip to content

maru3l/wp-rest-polylang

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 

Repository files navigation

wp-rest-polylang

description

Adds value lang and translations to WP REST api response for each Post and Page request for site running the Polylang plugin.

Values

lang

The locale value of the post

{
  [...]
  "polylang_current_lang": "en"
  [...]
}

translations

List of translation for the post

{
  [...]
  "polylang_translations": [
    {
      "locale": "fr",
      "id": 1
    }
  ],
  [...]
}

Releases

No releases published

Packages

No packages published

Languages