Skip to content

Commit

Permalink
v1.0.13 release
Browse files Browse the repository at this point in the history
This update contains a minor bug fix:
BorisMoore/jsviews#455: "Using a tmpl selector
that begins with a # but is not an ID selector does not work".

This change applies to jsrender and jsviews

The update also includes some minor documentation updates, and moves
to the latest versions of JQuery and JQuery UI, for all samples, examples,
and test pages.

Sync with other changes in v1.0.13 for JsViews
  • Loading branch information
BorisMoore committed Mar 31, 2023
1 parent 75f2059 commit 2440b69
Show file tree
Hide file tree
Showing 45 changed files with 72 additions and 68 deletions.
2 changes: 1 addition & 1 deletion demos/scenarios/01_default-values-scenario.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
2 changes: 1 addition & 1 deletion demos/scenarios/02_separators-scenario.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jquery-1.8.0.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />
Expand Down
2 changes: 1 addition & 1 deletion demos/scenarios/03_iterating-through-fields-scenario.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
2 changes: 1 addition & 1 deletion demos/scenarios/04_assigning-variables-scenario.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
2 changes: 1 addition & 1 deletion demos/scenarios/05_arrays-plus-headers-and-footers.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
2 changes: 1 addition & 1 deletion demos/step-by-step/01_inserting-data.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />
</head>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
2 changes: 1 addition & 1 deletion demos/step-by-step/03_converters-and-encoding.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
2 changes: 1 addition & 1 deletion demos/step-by-step/04_if-else-tag.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
2 changes: 1 addition & 1 deletion demos/step-by-step/05_for-tag.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
2 changes: 1 addition & 1 deletion demos/step-by-step/06_template-composition.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
2 changes: 1 addition & 1 deletion demos/step-by-step/07_paths.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />
</head>
Expand Down
2 changes: 1 addition & 1 deletion demos/step-by-step/08_custom-tags.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
2 changes: 1 addition & 1 deletion demos/step-by-step/09_helper-functions.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
2 changes: 1 addition & 1 deletion demos/step-by-step/10_comparison-tests.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
2 changes: 1 addition & 1 deletion demos/step-by-step/11_accessing-parent-data.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
2 changes: 1 addition & 1 deletion demos/step-by-step/12_passing-in-context.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../jsrender.js" type="text/javascript"></script>
<link href="../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../../jsrender.js" type="text/javascript"></script>
<link href="../../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../../jsrender.js" type="text/javascript"></script>
<link href="../../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../../jsrender.js" type="text/javascript"></script>
<link href="../../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../../jsrender.js" type="text/javascript"></script>
<link href="../../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js" type="text/javascript"></script>
<script src="//code.jquery.com/jquery-3.6.4.js" type="text/javascript"></script>
<script src="../../../jsrender.js" type="text/javascript"></script>
<link href="../../resources/demos.css" rel="stylesheet" type="text/css" />

Expand Down
6 changes: 3 additions & 3 deletions jsrender-node.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
/*! JsRender v1.0.12: http://jsviews.com/#jsrender */
/*! JsRender v1.0.13: http://jsviews.com/#jsrender */
/*! **VERSION FOR NODE.JS** (For WEB see http://jsviews.com/download/jsrender.js) */
/*
* Best-of-breed templating in browser or on Node.js.
* Does not require jQuery, or HTML DOM
* Integrates with JsViews (http://jsviews.com/#jsviews)
*
* Copyright 2021, Boris Moore
* Copyright 2023, Boris Moore
* Released under the MIT License.
*/

Expand All @@ -20,7 +20,7 @@ if (typeof exports !== 'object' ) {
//========================== Top-level vars ==========================

// global var is the this object, which is window when running in the usual browser environment
var versionNumber = "v1.0.12",
var versionNumber = "v1.0.13",
$, jsvStoreName, rTag, rTmplString, topView, $views,
_ocp = "_ocp", // Observable contextual parameter

Expand Down
6 changes: 3 additions & 3 deletions jsrender.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! JsRender v1.0.12: http://jsviews.com/#jsrender */
/*! JsRender v1.0.13: http://jsviews.com/#jsrender */
/*! **VERSION FOR WEB** (For NODE.JS see http://jsviews.com/download/jsrender-node.js) */
/*
* Best-of-breed templating in browser or on Node.js.
Expand Down Expand Up @@ -44,7 +44,7 @@ var setGlobals = $ === false; // Only set globals if script block in browser (no

$ = $ && $.fn ? $ : global.jQuery; // $ is jQuery passed in by CommonJS loader (Browserify), or global jQuery.

var versionNumber = "v1.0.12",
var versionNumber = "v1.0.13",
jsvStoreName, rTag, rTmplString, topView, $views, $expando,
_ocp = "_ocp", // Observable contextual parameter

Expand Down Expand Up @@ -1118,7 +1118,7 @@ function compileTmpl(name, tmpl, parentTmpl, options) {
}
} else if (value.charAt(0) === "#") {
elem = document.getElementById(value.slice(1));
} else if ($.fn && !$sub.rTmpl.test(value)) {
} if (!elem && $.fn && !$sub.rTmpl.test(value)) {
try {
elem = $(value, document)[0]; // if jQuery is loaded, test for selector returning elements, and get first element
} catch (e) {}
Expand Down
4 changes: 2 additions & 2 deletions jsrender.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion jsrender.min.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "jsrender",
"version": "v1.0.12",
"version": "v1.0.13",
"description": "Best-of-breed templating in browser or on Node.js (with Express 4, Hapi and Browserify integration)",
"main": "./jsrender-node.js",
"browser": "./jsrender.js",
Expand Down
8 changes: 4 additions & 4 deletions test/browserify/bundles/1-bundle.js

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions test/browserify/bundles/12-nested-bundle.js

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions test/browserify/bundles/2-bundle.js

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions test/browserify/bundles/3-bundle.js

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions test/browserify/bundles/htm-jsrender-tmpl-bundle.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
/*! JsRender v1.0.12: http://jsviews.com/#jsrender */
/*! JsRender v1.0.13: http://jsviews.com/#jsrender */
/*! **VERSION FOR WEB** (For NODE.JS see http://jsviews.com/download/jsrender-node.js) */
/*
* Best-of-breed templating in browser or on Node.js.
Expand Down Expand Up @@ -45,7 +45,7 @@ var setGlobals = $ === false; // Only set globals if script block in browser (no

$ = $ && $.fn ? $ : global.jQuery; // $ is jQuery passed in by CommonJS loader (Browserify), or global jQuery.

var versionNumber = "v1.0.12",
var versionNumber = "v1.0.13",
jsvStoreName, rTag, rTmplString, topView, $views, $expando,
_ocp = "_ocp", // Observable contextual parameter

Expand Down Expand Up @@ -1119,7 +1119,7 @@ function compileTmpl(name, tmpl, parentTmpl, options) {
}
} else if (value.charAt(0) === "#") {
elem = document.getElementById(value.slice(1));
} else if ($.fn && !$sub.rTmpl.test(value)) {
} if (!elem && $.fn && !$sub.rTmpl.test(value)) {
try {
elem = $(value, document)[0]; // if jQuery is loaded, test for selector returning elements, and get first element
} catch (e) {}
Expand Down
6 changes: 3 additions & 3 deletions test/browserify/bundles/html-jsr-tmpl-bundle.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
/*! JsRender v1.0.12: http://jsviews.com/#jsrender */
/*! JsRender v1.0.13: http://jsviews.com/#jsrender */
/*! **VERSION FOR WEB** (For NODE.JS see http://jsviews.com/download/jsrender-node.js) */
/*
* Best-of-breed templating in browser or on Node.js.
Expand Down Expand Up @@ -45,7 +45,7 @@ var setGlobals = $ === false; // Only set globals if script block in browser (no

$ = $ && $.fn ? $ : global.jQuery; // $ is jQuery passed in by CommonJS loader (Browserify), or global jQuery.

var versionNumber = "v1.0.12",
var versionNumber = "v1.0.13",
jsvStoreName, rTag, rTmplString, topView, $views, $expando,
_ocp = "_ocp", // Observable contextual parameter

Expand Down Expand Up @@ -1119,7 +1119,7 @@ function compileTmpl(name, tmpl, parentTmpl, options) {
}
} else if (value.charAt(0) === "#") {
elem = document.getElementById(value.slice(1));
} else if ($.fn && !$sub.rTmpl.test(value)) {
} if (!elem && $.fn && !$sub.rTmpl.test(value)) {
try {
elem = $(value, document)[0]; // if jQuery is loaded, test for selector returning elements, and get first element
} catch (e) {}
Expand Down
2 changes: 1 addition & 1 deletion test/perf-compare.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<head>
<title>Benchmark JsRender</title>
<link href="resources/perf-compare.css" rel="stylesheet" type="text/css" />
<script src="//code.jquery.com/jquery-3.6.1.js"></script>
<script src="//code.jquery.com/jquery-3.6.4.js"></script>
<script src="../jsrender.js" type="text/javascript"></script>
<script src="resources/jquery.tmpl.js" type="text/javascript"></script>

Expand Down
2 changes: 1 addition & 1 deletion test/test.min.map.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-3.6.1.js"></script>
<script src="//code.jquery.com/jquery-3.6.4.js"></script>
<script src="../jsrender.min.js"></script>
</head>
<body>
Expand Down
2 changes: 1 addition & 1 deletion test/unit-tests-amd-scriptloader.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<head>
<link href="//code.jquery.com/qunit/qunit-1.21.0.css" rel="stylesheet" type="text/css" />

<script src="//code.jquery.com/jquery-3.6.1.js"></script>
<script src="//code.jquery.com/jquery-3.6.4.js"></script>
<script src="//code.jquery.com/qunit/qunit-1.21.0.js"></script>

<script src="requirejs/require.js"></script>
Expand Down
2 changes: 1 addition & 1 deletion test/unit-tests-browserify.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<html>
<head>
<link href="//code.jquery.com/qunit/qunit-1.21.0.css" rel="stylesheet" type="text/css" />
<script src="//code.jquery.com/jquery-3.6.1.js"></script>
<script src="//code.jquery.com/jquery-3.6.4.js"></script>
<script src="//code.jquery.com/qunit/qunit-1.21.0.js"></script>
</head>
<body>
Expand Down
2 changes: 1 addition & 1 deletion test/unit-tests-jsrender-no-jquery.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

<script src="../jsrender.js"></script>

<script src="//code.jquery.com/jquery-3.6.1.js"></script>
<script src="//code.jquery.com/jquery-3.6.4.js"></script>
<script src="//code.jquery.com/qunit/qunit-1.21.0.js"></script>

<script src="unit-tests/tests-jsrender-no-jquery.js"></script>
Expand Down
2 changes: 1 addition & 1 deletion test/unit-tests-jsrender-with-jquery.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<head>
<link href="//code.jquery.com/qunit/qunit-1.21.0.css" rel="stylesheet" type="text/css" />

<script src="//code.jquery.com/jquery-3.6.1.js"></script>
<script src="//code.jquery.com/jquery-3.6.4.js"></script>
<script src="//code.jquery.com/qunit/qunit-1.21.0.js"></script>

<script src="../jsrender.js"></script>
Expand Down
6 changes: 3 additions & 3 deletions test/unit-tests/requirejs-config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
// Configure loading modules from the download directory,
requirejs.config({
"baseUrl": "//www.jsviews.com/download", // Or point to correct local path on your system: "baseUrl": "/download",
// "baseUrl": "../../download", // Or point to correct local path on your system: "baseUrl": "/download",
"baseUrl": "//www.jsviews.com/download", // Or point to correct local path on your system: "baseUrl": "../../",
// "baseUrl": "../../", // Or point to correct local path or URL on your system,
"paths": {
"jquery": "//code.jquery.com/jquery-3.5.1",
"jquery": "//code.jquery.com/jquery-3.6.4",
"jsrender": "./jsrender",
"jquery.observable": "./jquery.observable",
"jquery.views": "./jquery.views",
Expand Down
4 changes: 4 additions & 0 deletions test/unit-tests/tests-jsrender-with-jquery.js
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,10 @@ QUnit.test("render", function(assert) {

$("#result").html("<script id='tmpl' type='text/x-jsrender'>Content{{for #data}}{{:#index}}{{/for}}{{:~foo}}</script>");
assert.equal($("#tmpl").render([null, undefined, 1], true), "Content012", 'render(array, true) renders an array without iteration');

$("#result").html('<div id="people"><script class="item-tmpl" type="text/x-jsrender">{{:name}}</script></div>');
assert.equal($.templates("#people .item-tmpl").render({name: 'John'}), "John", 'Access template using "descendant" selector (with space): "#people .item-tmpl"');

$("#result").empty();
});

Expand Down
Loading

0 comments on commit 2440b69

Please sign in to comment.