tag:blogger.com,1999:blog-3627888979577168137.post6810997513254768644..comments2023-03-26T00:54:12.803-07:00Comments on Dancing with Data: Welcome to jsviews.com - the documentation and download site for JsViews, JsRender and JsObservableBoris Moorehttp://www.blogger.com/profile/17923416771395046921noreply@blogger.comBlogger12125tag:blogger.com,1999:blog-3627888979577168137.post-64915528952250655202015-01-20T12:12:21.256-08:002015-01-20T12:12:21.256-08:00See ongoing discussion here: github.com/BorisMoore...See ongoing discussion here: <a href="https://github.com/BorisMoore/jsviews/issues/293" rel="nofollow">github.com/BorisMoore/jsviews/issues/293</a><br /><br />This will be supported using the syntax <i>data-link="{if expr1 tmpl='#ifTmpl'}{else expr2 tmpl='#else2Tmpl'}{else expr3 tmpl='#else3Tmpl'}{else tmpl='#noneTmpl'}"</i>Boris Moorehttps://www.blogger.com/profile/17923416771395046921noreply@blogger.comtag:blogger.com,1999:blog-3627888979577168137.post-56384414999202169902015-01-09T10:03:52.060-08:002015-01-09T10:03:52.060-08:00i would be grateful if you ping me via e-mail, upo...i would be grateful if you ping me via e-mail, upon the event of answering.<br />"the.silly.sad" at gmail.<br /><br />thanx in advance.<br />and yes, jsrender is indeed best of breed Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-3627888979577168137.post-16175699981873449942015-01-09T10:00:29.541-08:002015-01-09T10:00:29.541-08:00I am using JsViews for my experimental website, an...I am using JsViews for my experimental website, and i have failed to use the "for-else" combination properly (in the context of a data-linked tag).<br />could you please clarify this tiny detail?<br />Having provided the data linked tag along with all necessary external templates:<br /><div data-link="{for Players tmpl='#player'}"><br /><br />how should i add an "else" branch properly?<br /><br />my wild guess does not work:<br /><div data-link="{for Players tmpl='#player' else='#noplayer'}"><br /> Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-3627888979577168137.post-64753574403341620002014-01-22T10:21:00.301-08:002014-01-22T10:21:00.301-08:00@Niranjan: Sorry not to have answered sooner. I do...@Niranjan: Sorry not to have answered sooner. I don't believe they are compliant as is, because template compilation uses new Function(). However pre-compilation should be very easy. See <a href="https://github.com/BorisMoore/jsrender/issues/30" rel="nofollow">jsrender/issues/30</a> and <a href="https://github.com/BorisMoore/jsrender/issues/164" rel="nofollow">jsrender/issues/164</a> . A precompile tool is planned for V1 or V1.1.<br /><br />As to the release date, I have made a lot of progress with some important updates - just released. (I was heads down on that which is why this answer is only coming now). So the bits are almost complete for the V1. However there is still a fair bit of documentation work to be done. The official V1 is probably still 2 or 3 months out.Boris Moorehttps://www.blogger.com/profile/17923416771395046921noreply@blogger.comtag:blogger.com,1999:blog-3627888979577168137.post-70368223015129527622014-01-03T09:01:35.042-08:002014-01-03T09:01:35.042-08:00Boris, Thanks on the great work.
I have 2 questi...Boris, Thanks on the great work. <br /><br />I have 2 questions. <br />I am planning to use JSRender and JSViews for a Chrome Packaged App. Are these libraries CSP compliant?<br />Second one, do you have an update on v 1.0 release date?<br /><br />Thanks,<br />NiranjanAnonymoushttps://www.blogger.com/profile/00679478433172939840noreply@blogger.comtag:blogger.com,1999:blog-3627888979577168137.post-41901853725197379222013-11-18T21:27:11.736-08:002013-11-18T21:27:11.736-08:00@Rahul: Yes, absolutely, they will move to 1.0 and...@Rahul: Yes, absolutely, they will move to 1.0 and beyond. While things have been slower than anticipated, there has been important progress, with more and more documentation topics on <a href="http://www.jsviews.com" rel="nofollow">www.jsviews.com</a>, and with a continuously improving feature set and quality level. See recent commits on the GitHub projects for <a href="https://github.com/BorisMoore/jsviews/commits/master" rel="nofollow">JsViews</a> and <a href="https://github.com/BorisMoore/jsviews.com/commits/master" rel="nofollow">jsviews.com</a>, to get a sense of that. (Another important update will be coming in a couple of days).<br /><br />The roadmap is to first complete the documentation of JsViews and JsRender at <a href="http://www.jsviews.com" rel="nofollow">www.jsviews.com</a>, then to declare the official Beta for JsViews, and then to move both JsRender and JsViews to the official V1.0 release.Boris Moorehttps://www.blogger.com/profile/17923416771395046921noreply@blogger.comtag:blogger.com,1999:blog-3627888979577168137.post-82776566405882085772013-11-16T18:19:00.457-08:002013-11-16T18:19:00.457-08:00Hi Boris,
Thanks for the Great work.
I was wonderi...Hi Boris,<br />Thanks for the Great work.<br />I was wondering if JSRender and JSView would ever move to the 1.0 and further. <br />I think its still in Beta and was wondering if any more updates were on the way.<br /><br /><br />Rahulhttps://www.blogger.com/profile/08073037896591839115noreply@blogger.comtag:blogger.com,1999:blog-3627888979577168137.post-75468476685675371752013-07-15T03:19:13.106-07:002013-07-15T03:19:13.106-07:00Great work! Keep it up!
I'm looking forward to...Great work! Keep it up!<br />I'm looking forward to using JsViews on my next projects.Bruno Cassolhttps://www.blogger.com/profile/17434283863630861378noreply@blogger.comtag:blogger.com,1999:blog-3627888979577168137.post-82431936705015175052013-06-20T12:18:41.727-07:002013-06-20T12:18:41.727-07:00@Anon: Yes, totally. JsRender is already an offici...@Anon: Yes, totally. JsRender is already an official beta, at the same level of quality at least as jQuery Templates, and with a feature-set which is a superset of jQuery Templates.<br /><br />So I recommend moving to JsRender or JsViews, rather than using jQuery templates. Moving forward, I will communicate that message more strongly, but already this is indicated in the ReadMe of JsRender, and elsewhere.Boris Moorehttps://www.blogger.com/profile/17923416771395046921noreply@blogger.comtag:blogger.com,1999:blog-3627888979577168137.post-32096303766804897962013-06-20T12:14:52.088-07:002013-06-20T12:14:52.088-07:00@Lee Timmins: Yes, good question. That is already ...@Lee Timmins: Yes, good question. That is already supported. I have just created a <a href="http://www.jsviews.com/#samples/editable" rel="nofollow">series of samples</a> which include that <a href="http://www.jsviews.com/#samples/editable/toplevelfor" rel="nofollow">specific scenario</a>.<br /><br />In fact you can use any tag you want as part of data-link, including custom tags: <em>data-link="{mytag a b x=yyy tmpl=...}"</em>.<br /><br />For example in <a href="http://www.jsviews.com/#samples/tagcontrols/multiselect" rel="nofollow">this sample</a> you have the syntax: <em><select data-link="{multisel items=items selected=selectedItems}"></select></em> Boris Moorehttps://www.blogger.com/profile/17923416771395046921noreply@blogger.comtag:blogger.com,1999:blog-3627888979577168137.post-76806088163453454842013-06-18T05:32:57.907-07:002013-06-18T05:32:57.907-07:00Nice work. This had started off as an offshoot to ...Nice work. This had started off as an offshoot to replace jquery templates. Is that still on the roadmap? Kiranhttps://www.blogger.com/profile/01868417349166711212noreply@blogger.comtag:blogger.com,1999:blog-3627888979577168137.post-44640524648690839092013-06-18T03:07:11.194-07:002013-06-18T03:07:11.194-07:00Great work. I had been worried this project had be...Great work. I had been worried this project had become stale. I've been reading through the documentation and something which may be new or passed me by is the following syntax:<br /><br />{{for pathOrExpr tmpl=nameOrExpr /}}<br /><br />When I bind to an element outside of a script template I use the data-bind syntax as it's valid HTML. For example. Say I have the following HTML:<br /><br /><div id="person"><br /> Name: <span data-link="name"></span><br /></div><br /><br />With the following code to link the data to the HTML:<br /><br />var person = {<br /> "name": "Pete",<br /> "addresses": [<br /> { "city": "London" },<br /> { "city": "Paris" }<br /> ]<br />};<br /><br />$('#person').link(true, person);<br /><br />This works great but now say I wish to display the addresses. I'd like to be able to change my HTML to something like the following:<br /><br /><div id="person"><br /> Name: <span data-link="name"></span><br /> Addresses: <ul data-link="for addresses tmpl=addressTemplate" /><br /></div><br /><script id="addressTemplate" type="text/x-jsrender"><br /> <li>{{>city}}</li><br /></script><br /><br />Any ideas whether/when something like this will be supported in the future?Anonymousnoreply@blogger.com