Skip to content
inspiraller edited this page Sep 7, 2011 · 2 revisions

What is STQuery?

STQuery is very much like jQuery, but instead of manipulating html elements on the DOM, as jQuery does, STQuery manipulates directly on a string.

What are the advantages of STQuery over jQuery?

STQuery is useful when when you want to manipulate HTML from an AJAX response, before writing it to the page. With jQuery you are constantly writing to the DOM with every manipulation, potentially causes user interaction delays with page reflows and repaints.

STQuery is especially beneficial for server side management of html templates. Developers can keep their html templates free of logic and use STQuery to manipulate the HTML dynamically, or to generate the final html before outputing to production. jQuery only works on the client. STQuery can be refactored to work on the server – for example it can be written in C#, php, velocity etc…

STQuery is in its alpha form and still requires thorough testing and further development. It doesn’t support half the features jQuery does, nor does it boast such a massive fan base. jQuery is one of the most popular javasript libaries in the world, and that is why STQuery is designed to be familiar to jQuery users.

What are the minimum requirements for STQuery to work?

Only that the HTML or xml being manipulated is well formed. It doesn’t have to be strictly valid, just as long as all open tags are correctly closed.

Clone this wiki locally