As suggested in comments, for a single file or for multiple files located on the same level in the archive, the option --strip-components=N, works fine.
The other GNU tar option that works for any number of files located anywhere in the archive is --xform (or --transform).
It allows modifying file names using a sed-like replace expression of the form:
s/regexp/replace/[flags]
so in your case the expression s|.*/|| removes all leading components from the file path i.e.
tar xvf gh_2.5.1_linux_armv6.tar.gz --xform='s|.*/||' gh_2.5.1_linux_armv6/bin/gh
extracts only the gh file (without any parent directories) in the current directory. Also, one can see the requested transformations applied with the --show-transformed-names option e.g. dry run:
tar -tf archive.tar.gz --xform='s|.*/||' --show-transformed-names
This can be combined with other options, e.g. extract based on pattern, to another directory:
tar -xvzf archive.tar.gz --xform='s|.*/||' -C dest_dir --wildcards --no-anchored 'match*'