Adding header links post vdom upgrade

I haven’t played around with it much, but this should get you started:

<script type="text/discourse-plugin" version="0.4">
api.decorateWidget('header-icons:before', helper => {
    const showExtraInfo = helper.attrs.minimized;
        if(!showExtraInfo) {
            return helper.h('div#test-links', [
                helper.h('a#test1', {
                    href:'/t/joining-sih/494', 
                    text:'Join Us!'
                }),
            ]);
        }
});
</script>
div#test-links {
    display: inline;
    float: left;
}
4 לייקים