On Tue, Apr 21, 2009 at 03:42:44PM -0000, Abel Deuring wrote:
> (2) If a '"' (double quotation mark) appears in JS, we'll get an error when the template is parsed. This leads to ugly, difficult to read code like node.set('innerHTML', '<a id=\'x\' class=\'y\' href=\'z\'>')
This is because we use tal:replace="string: $js-code", in order to be
able to easily customize the code, getting data from python. Moving the
code to a separate file won't make this any better.
On Tue, Apr 21, 2009 at 03:42:44PM -0000, Abel Deuring wrote: 'innerHTML' , '<a id=\'x\' class=\'y\' href=\'z\'>')
> (2) If a '"' (double quotation mark) appears in JS, we'll get an error when the template is parsed. This leads to ugly, difficult to read code like node.set(
This is because we use tal:replace= "string: $js-code", in order to be
able to easily customize the code, getting data from python. Moving the
code to a separate file won't make this any better.