Find the route name of the current page in Drupal 8
I was trying to generate a dynamic link to a Drupal Commerce product but couldn't figure out the correct route name. I finally got the route name with the following debugging code:
I was trying to generate a dynamic link to a Drupal Commerce product but couldn't figure out the correct route name. I finally got the route name with the following debugging code: