About front end structure

AI-generated summary

A discussion about the front-end structure of Discourse is underway. Chong_An_Chen inquired about the feasibility of sharing functionalities across Ember, widget, and raw.hbs front-end code types, and sought opinions on the maintainability of the current structure. pfaffman and merefield suggested reviewing the theme and plugin development tutorials, including a post on meta.discourse.org. pfaffman later responded that Chong_An_Chen’s questions were too vague, advising to follow plugin tutorial examples and confirming that the current front-end structure is good and easy to maintain.

as far as I know, there are three ways to build front-end code,

  1. ember
  2. widget
  3. raw.hbs (?

and there are some questions:

  1. I’ve tried to use ember component in raw.hbs, but it seems not working, how to share all the functionalities in these three types of front end code?

  2. sorry, I’ve not fully understood the entire code yet, but just want to ask about the front end structure,
    is it a good structure? is it easy to maintain?

thanks

See the howto topics on theme and plugin development.

I’ve read all of the theme and plugin tutorial, but I still could not do it, could you answer the two questions above?

Further reading and watching here:

Your questions are so vague that they don’t really have answers.

Follow the examples in the plugin tutorials. Everything is cached in production. You can’t just edit the stuff and have it work.

Yes.