DPDK Architecture  ->  Library (v3.4.4)

useGlossary

useGlossary is a core functionality that provides multilingual copy from a CMS.

Usage

The glossary module exports different functions of which only one has to be used: useGlossary. The other functions are for internal use by the architecture and will not be documented.

Basic usage

Using the glossary couldn't be easier, call the hook and everything else is done automatically:

function Home() {
  const glossary = useGlossary();
  return <h1>{glossary.title}</h1>;
}

To switch the language you can use <Language /> component provided here.

Last modifiedWednesday, February 3, 2021, 10:17:16 AM UTC
Last authorColin van Eenige
Commit IDa5fc248