Using templates and data pipelining for app profile view

Friday, March 6, 2009 at 2:48 AM



We're excited to announce the availability of server-side OS templates and data pipelining on the orkut sandbox. Data pipelining allows you to specify the data you want to use in your app, while templates let you describe how to render the app - all using a markup language (that's right, no JavaScript!). Using data pipelining and templates will reduce the number of round trips between the container and your server, making your app render faster. Moreover, template values are HTML-escaped thus plugging many XSS vulnerabilities automatically.

Since the profile view of an app doesn't require interactivity, server-side OS templates and data pipelining are a good fit for this view. We will soon be rendering apps that use these templates in the profile page. Our goal is to eventually allow only server-side OS templates in the profile view and at that point, all other active content including JavaScript and Flash will be stripped out when displaying the profile view of an app. We are confident that by leveraging these features, you will generate more usage for your apps, with reduced latency and make them safer for users.

These new features are currently available on the orkut sandbox, so you can start developing with them today. For more information (including examples), please see the OpenSocial Templates Developer's Guide , the OpenSocial Templates tutorial and the Data Pipelining tutorial. We know that OS templates are currently missing some capabilities that are required to build good profile views. At the top of our list are support for os:NavigateToView and ability to interpret JSON appdata. We'll be adding them soon.

Do check them out and give us your feedback.