This is the close vote queue entry. It is for this question. I voted to close for a custom reason:
I'm voting to close because this question sounds more like a request for code review, and the last part asks for alternative implementations in a way that doesn't give explicit guidelines for constructive discussion and instead leaves things open-ended.
The part(s) of the question I am referring to is:
After lots of time looking for solution i came up with using createListenerMiddleware. Could someone tell me if this is a good idea, and if not, is there any other way of doing it properly.
<their code>
I feel like simply asking if something is a good idea doesn't make for a good question. If I were asking the question I would have tried to describe some specific things that would qualify a good idea for me.
The question didn't explicitly ask for code review, but the combination of asking if their approach "is a good idea", and asking for proposed alternatives seems in my mind like it passes the Duck Test.
Asking for code review seems like it violates the guideline on having a specific programming-related question. There can be tons of ways a given piece of code can be improved, some obvious, and some involving tradeoffs. While I can see that kind of content being useful to people other than the original asker of the question, I have a feeling that proliferation of such questions would probably include lots of questions that are low quality, and that the useful information from answers would be hard to make discoverable on search engines. I did a bit of searching on whether code review questions are allowed on stackoverflow.com and found this MSE post saying no, and the "guide-to-code-review-for-stack-overflow-users". I think this question matches the requirement of "Finished, working code that does what it is meant to do + Ideally, an asker willing to receive feedback on any aspect of the code".
I tagged with disputed-review-audits for categorization purposes, but I'm really looking for feedback instead of trying to assert what I think is right or wrong. Can I please have feedback on my line of thought? Was my reasoning appropriate / in line with the rules and guidelines for Stack Overflow?