Wouldn't it be cool if we could have the same uri_for feature we have on the Perl side, on the JS side? Not exactly sure how we could accomplish this, but in theory with the same metadata it should be possible to port the code.