Response
When spark said quoting was supported I thought they meant forum-style quoting
which is just this, but with a link to the original post and usually the ability to collapse the quote
not twitter-style quoting, which I don't like as much, but it's nice that it's here
Comment
Reactions
Replies
Add a reply
Continually impressed by how dedicated you are to making this site great, thanks for the unexpected comment!
Yeah, this is unfortunately the best way to do it though. You've always been able to quote things this way (the "Follow-up" button has always used this), but I've changed the way they look now because it was needed to improve performance.
When we pulled responses previously, we did this:
Since we render everything on the server, this quickly stacked up to a page containing 50 responses ending up with 100 responses. For every single response, we also fetch the author and its question (+ the question's author) if applicable. This means we were running over 200 SQL queries to load a single 50 response page.
This quickly tanked performance on profiles which uses "Follow-up" a lot, leading to >1500ms load times.
Since I've been splitting the
templates/
directory into using "partials" (sub templates which are just a single component), I decided to add a partial for rendering responses:https://neospring.org/_app/components/response.html?id=7418214140306cbe06159b5770b62a853bfc09ed2deafe0d778f1b5392e0c15e&do_render_nested=false
(Note this is the same way chat messages are rendered! We still render everything on the server, just at different times now.)
The has taken load times on such heavy profiles from 1s+ to around 400ms on average. I had to change the template for follow-ups because:
include-partial
custom element, which is like an iframe if it didn't use ShadowDOM. It's much easier to make a clean HTML template using this instead of the other solutionAnyway, hope that helps explain some things! Forum-style quoting has also been mostly supported, though, since that's mainly just on the Markdown parser (except for the interactions).