# Mounting widget in raw template?

**URL:** <https://meta.discourse.org/t/mounting-widget-in-raw-template/44400>\
**Category:** Development\
**Created:** [17. Mai 2016 um 19:15 UTC](https://meta.discourse.org/t/mounting-widget-in-raw-template/44400 "2016-05-17T19:15:56Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![joebuhlig](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/joebuhlig/32/193054_2.png) [@joebuhlig](https://meta.discourse.org/u/joebuhlig)\
**Post date:** [17. Mai 2016 um 19:15 UTC](https://meta.discourse.org/t/mounting-widget-in-raw-template/44400/1 "2016-05-17T19:15:56Z")

</div>

Part of what I love about the [new widget structure](https://meta.discourse.org/t/a-tour-of-how-the-widget-virtual-dom-code-in-discourse-works/40347) is being able to reuse code in multiple places. But I’ve run into an issue when attempting to do this for the [voting plugin](https://meta.discourse.org/t/discourse-feature-voting/40121).

I use widgets heavily on the page for an individual topic. It makes the build process much smoother. But I want to take the base parent widget I’ve built for the topic page and place it on the topic list. That would allow the user to interact with the topic from the list itself. This is easily the most common request I get for this plugin.

However, since the topic list is built using raw handlebars templates, you [can’t mount a widget there](https://meta.discourse.org/t/a-tour-of-how-the-widget-virtual-dom-code-in-discourse-works/40347/39).

I can get this done by reopening the [topic list component](https://github.com/discourse/discourse/blob/master/app/assets/javascripts/discourse/components/topic-list-item.js.es6) and rebuilding the entire UI but that seems a bit extreme for something seemingly simple. I’m hoping someone has an idea for how to reuse a widget on a topic list. Thoughts?

---

_[View the full topic](https://meta.discourse.org/t/mounting-widget-in-raw-template/44400)._
