+ def inspect_string (self,msg):
+ result = 'Prelude.inspect %s (%s) with '%(msg,self)
+ result += ",".join( [ "%s->%s"%(k,len(getattr(self,k))) for k in ['js_files','js_chunks','css_files','css_chunks'] ] )
+ return result
+ def inspect (self,msg):
+ print self.inspect_string(msg)
+
+ # first attempt was to use a simple dict like this
+ # env={}
+ # env['js_files']= self.js_files
+ # env['css_files']= self.css_files
+ # env['js_chunks']= '\n'.join(self.js_chunks)
+ # env['css_chunks']='\n'.join(self.css_chunks)
+ # return env
+ # together with this in layout-myslice.html
+ # {% for js_file in js_files %} {% insert_str prelude js_file %} {% endfor %}
+ # {% for css_file in css_files %} {% insert_str prelude css_file %} {% endfor %}
+ # somehow however this would not work too well,
+ # probably insert_above is not powerful enough to handle that
+ #
+ # so a much simpler and safer approach is for use to compute the html header directly
+ def template_env (self):