Custom html/javascript in Sproutcore? -


is possible have custom html/javascript in sproutcore?

i have use code cloud service provider.

yes, rather easy. in view can define render() method:

app.myview = sc.view.extend({    render: function(context, firsttime) {     var somevalue = `getvalue`      context.push(       "<span class='myspan'>", somevalue, "</span>",       "any other html/javascript want, can go here."     );    }  }) 

you can use firsttime property know if rendering first time (put out everything), or updating existing code.

you can find out more:


Comments

Popular posts from this blog

python - Scipy curvefit RuntimeError:Optimal parameters not found: Number of calls to function has reached maxfev = 1000 -

java - where to store the user credentials in an enterprise application(EAI)? -

openxml - Programmatically format a date in an excel sheet using Office Open Xml SDK -