% arara: pdflatex
\documentclass{article}

\usepackage{glossaries-extra}

\newglossaryentry{sample}{name={sample},description={}}
\newglossaryentry{childex}{parent={sample},name={child example},description={}}

\begin{document}
\Glsxtrhiername{sample}.

\glsxtrhiername{childex}.

\end{document}
