Not sure if this is still relevant to you, but I followed your code and was getting the same results. The code wasn't firing despite having a console log in the theme.js file.
Then I decided to click on the 'Clone widgets from...' and selected 'Categories'. After that all of the .tpl names showed up in the drop down. After that any changes to the theme.js file are firing as should.
Make sure you build and restart. I am using the included GRUNT to make development faster. Cheers!
After some more code digging and experiments I can answer my own question. A theme is a normal plugin and as such does not inherit any behavior from other plugins.
So you need to copy everything you need from the base theme library.js to your child theme. And of course, you need to declare client scripts explicitly.
Loading of missing templates from base theme is the only link between the base and the child theme.
Hi, I have following:
My purpose is to use my own sort method for sorting topics in a category, automatically modifying visible "Sort By" html element with a special sorting method that I implemented, and make it selected automatically.
I tried many hooks but "filter:config.get" was only one that is called before rendering or sending anything to client side. Other hooks such as "filter:categories.buildTopicsSortedSet", "filter:categories.getSortedSetRangeDirection","filter:category.topics.prepare", they all didn't work.
For example, if I changed like following in a method for "filter:categories.buildTopicsSortedSet":
data.settings.categoryTopicSort = 'most_myown';
but in client side, it only shows the previous value of "data.settings.categoryTopicSort", not the value "most_myown".
So I had to use "filter:config.get" because changing config there actually reflects to client side.
To implement it, I first need to check information about category that the user just entered, and append it to config, and send it to client. They are supposed to be done in "configGet" method, which you see above. But I do not know how to get information about category that the user is in. I need to know about category info because my own sorting will only work for certain categories.
I have installed nodebb-plugin-question-and-answer v0.7.7 on nodebb v1.13.3. but when I post a topic as question, "mark this post as correct answer" is not available. "unsolved" tag is not appearing for topic which is posted as question. Please help me with this.