Add custom user routes using plugins

Hi Guys,

can someone please guide me how to add some custom user routes using plugins in discourse.

I have gone through the plugin creation tutorial and add an admin interface using the plugin but not able to get it to work for normal users.

Thanks.

The way you swing this is by prepending at / like so:

https://github.com/SamSaffron/blog/blob/d09f5ea409e4a3a5d4905f511273bc0566e21cff/plugin.rb#L83-L85

Then you can capture the route.

2 Likes

Thanks @sam for you response. Is there any other guide for making the things working in the Ember side as well as mounting engine will only add the URL in rails routes but how can we make that URL working over the ember side in case I want to add this custom functionality from plugin itself

Thanks