Let's take undodir
as an example; we might have something like this in our vimrc:
set undodir=$HOME/.config/nvim/undo/
In order to make config platform-agnostic one might want to use variables instead, eg
let conf_dir = stdpath('config')
set undodir=conf_dir.'/undo/' " this is problematic
The above example doesn't work - conf_dir
variable is not expanded as expected.