Having read about how D8's path system is different from D7, and having seen some 'simple' examples, I have tried
- setting a path variable in a preprocess functions and outputting that as a {{ my_path_variable }} in a twig template
- outputting {{ kint(my_path_variable) }} in the twig template
- outputting kint(my_path_variable) in the preprocess function
None of the above works, I only get NULL in my kint output.
I've read this page: Get the current path alias or path?, and I really don't know where I'm supposed to place the $current_path definition in order to get the path into a twig template, so I can output it as variable.