Print path to page without linking

I need to print out the path of any page for use in an ajax call inside a js.erb file. Not sure how to build the helper for this if one doesn’t already exist. Here’s what I’d like to do…

  $.ajax({
    url: "<%= path_to 'product.html' %>",
    context: document.body
  }).done(function(result) {
    console.log( result );
  });

Is there any reason you couldn’t just use the relative path, without a helper?

url: "/product.html"

Not sure exactly what you’re asking for.