Hm… here’s how far I got:
<script>
Discourse.HomeLogoComponent.reopen({
linkUrl: function() {
return Discourse.getURL('/latest');
}.property(),
});
</script>
Which works pretty well, since I get this a tag on my logo:
<a data-auto-route="true" href="/latest">
…but: if I click on the logo image, it takes me to Discourse.getURL('/'); (i.e. www.example.com instead of www.example.com/latest) in spite of the correct href attribute?! Wut?? Oh.
click: function(e) {
// if they want to open in a new tab, let it so
if (e.shiftKey || e.metaKey || e.ctrlKey || e.which === 2) { return true; }
e.preventDefault();
DiscourseURL.routeTo('/');
return false;
}
Really? You define a property linkUrl and override click events to a hard-coded ‘/’? ![]()
Trying to figure out how to import DiscourseURL now… if anyone has hints, I will be glad…