Client and Rack Middlware which submits URL's and HTML fragments to be rendered as a PDF
This is a TeX-to-HTML+MathML+CSS converter class using the Javascript-based KaTeX, interpreted by one of the Javascript engines supported by ExecJS. The intended purpose is to eliminate the need for math-rendering Javascript in the client's HTML browser. Therefore the name: SsKaTeX means Server-side KaTeX. Javascript execution context initialization can be done once and then reused for formula renderings with the same general configuration. As a result, the performance is reasonable. The configuration supports arbitrary locations of the external file katex.min.js as well as custom Javascript for pre- and postprocessing. For that reason, the configuration must not be left to untrusted users.
Email clients are not web browsers. They render html all funny, to put it politely. In general, the best practices for writing HTML that will look good in an email are the exact inverse from those that you should use for a web page. Remembering all those differences sucks.
RJS is a great Ruby DSL to write javascript. However, it's so tempting to write RJS directly in the views, and soon the views contain substantial controller knowledge (e.g. link_to_remote, link_to, etc) KRJS attempts to solve that problem by allowing dynamic inclusion of AJAX calls on HTML elements. When a controller defines a method (based on naming convention) that handles a client-side event, the rendering engine will do the wiring automatically - when the event happens, an AJAX call will be made to the controller's method which would ideally reply with RJS and update portions of the document.
RJS is a great Ruby DSL to write javascript. However, it's so tempting to write RJS directly in the views, and soon the views contain substantial controller knowledge (e.g. link_to_remote, link_to, etc) KRJS attempts to solve that problem by allowing dynamic inclusion of AJAX calls on HTML elements. When a controller defines a method (based on naming convention) that handles a client-side event, the rendering engine will do the wiring automatically - when the event happens, an AJAX call will be made to the controller's method which would ideally reply with RJS and update portions of the document.
+js-rails-routes+ is a utility for generating JavaScript equivalents to the +<route>_path+ functions provided by {Ruby on Rails}[https://github.com/rails/rails]. This allows you to do very similar things in your {+ejs+}[https://rubygems.org/gems/ejs/] JavaScript templates as you would in your +erb+ ruby templates. You can move html rendering to the client and keep it looking very similar to how it would look on the server. For example, if you have a model +Item+ and a simple route to list all the items, a link to that items page (using an explicit +a+ anchor tag instead of the Rails +link_to+) would look the same in either an +erb+ file or an +ejs+ file: <a href="<%= items_path() %>">List all Items</a> This gem was originally developed as part of the {MVCoffee}[http://mvcoffee.org] suite of tools, and integrates strongly with the {mvcoffee.js}[https://github.com/kirkbowers/mvcoffee] CoffeeScript MVC framework.