Scrivito is proudly made by JustRelate Group in Berlin, Germany, and Wrocław, Poland.
Scrivito is proudly made by JustRelate Group
New in 1.18.0

getByPath(path)

Fetches the Obj with the given path from the site context.

frenchSite = Scrivito.Obj.onSite('fr');
frenchHomepage = frenchSite.getByPath("/");

console.log(frenchHomepage.get("title"));

Params

  • path (String) - The path of the Obj.

Returns

Obj | null - Obj if a CMS object with the given path exists and is assigned to the site, otherwise null.

See also

Obj.getByPath