can
Version:
MIT-licensed, client-side, JavaScript framework that makes building rich web applications easy.
600 lines (503 loc) • 36 kB
HTML
<!--####################################################################
THIS IS A GENERATED FILE -- ANY CHANGES MADE WILL BE OVERWRITTEN
INSTEAD CHANGE:
source: [object Object]
@page canjs
######################################################################## -->
<html lang="en">
<head>
<meta charset="utf-8">
<title>CanJS</title>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<link rel="stylesheet" type="text/css" href="doc/static/bundles/bit-docs-site/static.css">
<link rel="shortcut icon" sizes="16x16 24x24 32x32 48x48 64x64" href="/docs/images/canjs_favicon.ico">
<link rel="apple-touch-icon" sizes="57x57" href="docs/images/canjs_favicon_57x57.png">
<link rel="apple-touch-icon-precomposed" sizes="57x57" href="docs/images/canjs_favicon_57x57.png">
<link rel="apple-touch-icon" sizes="72x72" href="docs/images/canjs_favicon_72x72.png">
<link rel="apple-touch-icon" sizes="114x114" href="docs/images/canjs_favicon_114x114.png">
<link rel="apple-touch-icon" sizes="120x120" href="docs/images/canjs_favicon_128x128.png">
<link rel="apple-touch-icon" sizes="144x144" href="docs/images/canjs_favicon_144x144.png">
<link rel="apple-touch-icon" sizes="152x152" href="docs/images/canjs_favicon_152x152.png">
<meta content="yes" name="apple-mobile-web-app-capable">
<meta name="apple-mobile-web-app-status-bar-style" content="white-translucent">
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-2302003-11', 'auto');
ga('send', 'pageview');
</script>
</head>
<body>
<input type="checkbox" id="nav-trigger" class="nav-trigger"/>
<label for="nav-trigger">Menu</label>
<div id="everything">
<div id="left" class="column">
<div class="top-left">
<div class="brand">
<div class="logo">
<a href="index.html" alt="CanJS"></a>
<div class="dropdown project-dropdown">
<a href="https://donejs.com/">DoneJS</a>
<a href="http://stealjs.com/">StealJS</a>
<a href="http://jquerypp.com/">jQuery ++</a>
<a href="https://funcunit.com/">FuncUnit</a>
<a href="http://documentjs.com/">DocumentJS</a>
</div>
</div>
<div class="version">
<div class="version-number">
3.0.0
</div>
<div class="dropdown version-dropdown">
<a href="https://v2.canjs.com">2.3.27</a>
</div>
</div>
</div>
<div class="search-bar">
<p>
</p>
</div>
</div>
<div class="bottom-left">
<div class="social-side-container">
<ul class="social-side">
<li>
<a class="header-mobile github" href="https://github.com/canjs/canjs" target="_blank"><img class="social-icon-small" src="docs/images/github.png">Github</a>
</li>
<li>
<a class="header-mobile twitter" href="https://twitter.com/canjs" target="_blank"><img class="social-icon-small" src="docs/images/twitter.png">Twitter</a>
</li>
</ul>
<ul class="social-side">
<li>
<a class="header-mobile" href="https://gitter.im/canjs/canjs" target="_blank">Chat</a>
</li>
<li>
<a class="header-mobile" href="http://forums.donejs.com/c/canjs" target="_blank">Forum</a>
</li>
</ul>
</div>
<ul>
<li class="
">
<a class="page"
href="doc/guides.html"
title="Welcome to CanJS! These guides are here to help you develop and improve your relationship with CanJS. After all, picking a JavaScript framework is a commitment. We want CanJS to be the
framework you marry. This page helps you know how advance through the different stages of this
relationship:">
Guides
</a>
</li>
<li class="
">
<a class="page"
href="doc/can-core.html"
title="The best, most hardened and generally useful libraries in CanJS.">
Core
</a>
</li>
<li class="
">
<a class="page"
href="doc/can-ecosystem.html"
title="Useful libraries that extend or add important features to the core collection.">
Ecosystem
</a>
</li>
<li class="
">
<a class="page"
href="doc/can-infrastructure.html"
title="Utility libraries that power the core and ecosystem collection.">
Infrastructure
</a>
</li>
<li class="
">
<a class="page"
href="doc/can-legacy.html"
title="Former libraries that we still accept patches for, but are not under active development.">
Legacy
</a>
</li>
</ul>
</div>
</div>
<div id="right" class="column">
<div class="top-right">
<div class="top-right-top">
<ul class="top-right-bitovi">
<li class="dropdown">
<a href="http://bitovi.com" class="bitovi icon-bits">Bitovi</a>
<ul class="dropdown-menu">
<li><a href="http://bitovi.com">Bitovi.com</a></li>
<li><a href="http://bitovi.com/blog/">Blog</a></li>
<li><a href="http://bitovi.com/consulting/">Consulting</a></li>
<li><a href="http://bitovi.com/training/">Training</a></li>
<li><a href="http://bitovi.com/open-source/">Open Source</a></li>
</ul>
</li>
</ul>
<div class="brand">
<div class="logo">
<a href="index.html" alt="CanJS"></a>
</div>
</div>
<ul class="top-right-links">
<li>
<a href="https://gitter.im/canjs/canjs">Chat</a>
</li>
<li>
<a href="http://forums.donejs.com/c/canjs">Forum</a>
</li>
<li>
<a class="github-button nav-social" href="https://github.com/canjs/canjs" data-count-href="/canjs/canjs/stargazers" data-count-api="/repos/canjs/canjs#stargazers_count">Star</a>
</li>
<li>
<a href="https://twitter.com/canjs" class="twitter-follow-button nav-social" data-show-count="true" data-show-screen-name="false">Follow @canjs</a><script async src="//platform.twitter.com/widgets.js" charset="utf-8"></script>
</li>
</ul>
</div>
<div class="breadcrumb">
<li><a href="index.html">CanJS</a></li>
<li class="breadcrumb-dropdown">/ <a> On this page</a>
<ul class="on-this-page"></ul>
</li>
<div class="nav-toggle" title="Back to top"></div>
</div>
</div>
<div class="bottom-right">
<article>
<section class="title">
<div class="page-type">
<h1>CanJS</h1>
<div>page</div>
</div>
<section class="description">
<p>CanJS is an evolving and improving set of client side JavaScript architectural libraries that balances
innovation and stability. It targets experienced developers building complex applications with long futures ahead of them.</p>
<p><img
srcset="docs/images/home/Home-Tortoise-color.png 1x, docs/images/home/Home-Tortoise-bw-x2.png 2x"
src="docs/images/home/Home-Tortoise-color.png"
style="float:right; padding-right: 40px;"/>
<img
srcset="docs/images/home/Home-Hare-color.png 1x, docs/images/home/Home-Hare-bw-x2.png 2x"
src="docs/images/home/Home-Tortoise-color.png" style="padding-left: 40px;"/></p>
<p>If you're new to the framework, the best place to start is the <a href="doc/guides.html" title="Welcome to CanJS! These guides are here to help you develop and improve your relationship with CanJS. After all, picking a JavaScript framework is a commitment. We want CanJS to be the
framework you marry. This page helps you know how advance through the different stages of this
relationship:">Guides</a> page. There you'll
find CanJS's <a href="doc/guides/mission.html" title="Learn about CanJS's mission, why it matters, and how we've worked (and will keep working) to accomplish it.">Mission</a>, <a href="doc/guides/technical.html" title="">Technical Highlights</a> and
the <a href="doc/guides/chat.html" title="This guide walks through building real time chat application with CanJS's Core libraries. It takes about 30 minutes to complete.">Chat</a>, <a href="doc/guides/todomvc.html" title="This guide walks through building a slightly modified version of TodoMVC with CanJS's Core libraries and can-fixture. It takes about 1 hour to complete.">TodoMVC</a>, and <a href="doc/guides/atm.html" title="This guide walks through building and testing an ATM application with CanJS's
Core libraries. It teaches how to do test driven development (TDD)
and manage complex state. It takes about 2 hours to complete.">ATM</a> guide.</p>
</section>
</section>
<section class="on-this-page-table">
</section>
<section class="title-footer">
<ul class="title-social">
<li>
<a class="npm-button" href="https://www.npmjs.com/package/can">
<img src="https://img.shields.io/badge/npm%20package-3.0.0-brightgreen.svg" alt="npm package badge" />
</a>
</li>
<li>
<a class="github-button nav-social" href="https://github.com/canjs/canjs"
data-count-href="/canjs/canjs/stargazers"
data-count-api="/repos/canjs/canjs#stargazers_count">Star</a>
</li>
</ul>
<ul class="title-links">
<!-- <li><a href="#">docco</a></li> -->
<li><a href="//github.com/canjs/canjs/tree/v3.0.0/docs/can-canjs/canjs.md">source</a></li>
<!-- <li><a href="#">download</a></li> -->
<!-- <li><a href="#">tests</a></li> -->
</ul>
</section>
<section class="body">
<h2>Collections</h2>
<p>CanJS is made of many independent packages and modules. Those packages and modules are
organized within the following collections. Read on to get an overview of each collection's
packages. Please star what you like so we know where to put our effort.</p>
<h3><a href="doc/can-core.html" title="The best, most hardened and generally useful libraries in CanJS.">Core Collection</a></h3>
<p><em>The best, most hardened and generally useful libraries in CanJS.</em></p>
<div class="module-list">
<ul>
<li><strong><a href="doc/can-compute.html" title="Create an observable value.">can-compute</a></strong> <small>3.0.3</small> Observable values and observable composite values
<ul>
<li><code>npm install can-compute --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-compute" data-count-href="/canjs/can-compute/stargazers" data-count-api="/repos/canjs/can-compute#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-define.html" title="Exports the define method that defines observable properties and their behavior on a prototype object.">can-define</a></strong> <small>1.0.4</small> Observable objects
<ul>
<li><code>npm install can-define --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-define" data-count-href="/canjs/can-define/stargazers" data-count-api="/repos/canjs/can-define#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-set.html" title="can-set is a utility for comparing sets that are represented by the parameters commonly passed to service requests.">can-set</a></strong> <small>1.0.2</small> Service modeling
<ul>
<li><code>npm install can-set --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-set" data-count-href="/canjs/can-set/stargazers" data-count-api="/repos/canjs/can-set#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-connect.html" title="can-connect provides persisted data middleware. Use it to assemble powerful model layers for any JavaScript project.">can-connect</a></strong> <small>1.0.11</small> Data connection
<ul>
<li><code>npm install can-connect --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-connect" data-count-href="/canjs/can-connect/stargazers" data-count-api="/repos/canjs/can-connect#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-stache.html" title="Live binding Mustache and Handlebars-compatible templates.">can-stache</a></strong> <small>3.0.8</small> Live binding templates
<ul>
<li><code>npm install can-stache --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-stache" data-count-href="/canjs/can-stache/stargazers" data-count-api="/repos/canjs/can-stache#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-component.html" title="Create a custom element that can be used to manage widgets or application logic.">can-component</a></strong> <small>3.0.2</small> Custom elements
<ul>
<li><code>npm install can-component --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-component" data-count-href="/canjs/can-component/stargazers" data-count-api="/repos/canjs/can-component#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-stache-bindings.html" title="Provides template event, one-way, and two-way bindings.">can-stache-bindings</a></strong> <small>3.0.4</small> View bindings
<ul>
<li><code>npm install can-stache-bindings --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-stache-bindings" data-count-href="/canjs/can-stache-bindings/stargazers" data-count-api="/repos/canjs/can-stache-bindings#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-route.html" title="Manage browser history and client state by synchronizing the window.location.hash with a map.">can-route</a></strong> <small>3.0.3</small> Routing
<ul>
<li><code>npm install can-route --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-route" data-count-href="/canjs/can-route/stargazers" data-count-api="/repos/canjs/can-route#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-route-pushstate.html" title="Changes can-route to use pushstate
to change the window's pathname instead
of the hash.
var route = require("can-route-pushstate");
route("{page}", { page: "home" });
route.ready();
route.attr("page", "user");
location.pathname; // -> "/user"">can-route-pushstate</a></strong> <small>3.0.0</small> Pushstate routing
<ul>
<li><code>npm install can-route-pushstate --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-route-pushstate" data-count-href="/canjs/can-route-pushstate/stargazers" data-count-api="/repos/canjs/can-route-pushstate#stargazers_count">Star</a></li>
</ul></li>
</ul>
</div>
<h3><a href="doc/can-ecosystem.html" title="Useful libraries that extend or add important features to the core collection.">Ecosystem Collection</a></h3>
<p><em>Useful libraries that add important features or extend the core collection.</em></p>
<div class="module-list">
<ul>
<li><strong><a href="doc/can-fixture.html" title="can-fixture intercepts an AJAX request and simulates the response with a file or function.">can-fixture</a></strong> <small>1.0.7</small> Simulate AJAX requests
<ul>
<li><code>npm install can-fixture --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-fixture" data-count-href="/canjs/can-fixture/stargazers" data-count-api="/repos/canjs/can-fixture#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-zone.html" title="">can-zone</a></strong> <small>0.6.0</small> Track asynchronous activity
<ul>
<li><code>npm install can-zone --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-zone" data-count-href="/canjs/can-zone/stargazers" data-count-api="/repos/canjs/can-zone#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-stache-converters.html" title="Provides a set of converters useful for two-way binding with form elements such as <input> and <select>.">can-stache-converters</a></strong> <small>3.0.3</small> Form two way bindings helpers
<ul>
<li><code>npm install can-stache-converters --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-stache-converters" data-count-href="/canjs/can-stache-converters/stargazers" data-count-api="/repos/canjs/can-stache-converters#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/steal-stache.html" title="A StealJS extension that allows stache templates as dependencies.">steal-stache</a></strong> <small></small> Import can-stache templates as dependencies with <a href="http://stealjs.com" title="StealJS">StealJS</a>
<ul>
<li><code>npm install steal-stache --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/steal-stache" data-count-href="/canjs/steal-stache/stargazers" data-count-api="/repos/canjs/steal-stache#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-view-import.html" title="">can-view-import</a></strong> <small>3.0.1</small> Import modules within can-stache templates
<ul>
<li><code>npm install can-view-import --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-view-import" data-count-href="/canjs/can-view-import/stargazers" data-count-api="/repos/canjs/can-view-import#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-jquery.html" title="Extensions to the event system so that can events and jQuery events are cross-bound.
Importing can-jquery will return the jQuery object and wire up the event system.
var $ = require("can-jquery");
var div = $("<div>");
div.on("inserted", function(){
// it inserted!
});
$("body").append(div);">can-jquery</a></strong> <small>3.0.2</small> jQuery integrations
<ul>
<li><code>npm install can-jquery --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-jquery" data-count-href="/canjs/can-jquery/stargazers" data-count-api="/repos/canjs/can-jquery#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-construct-super.html" title="can.Construct.super is a plugin that makes it easier to call base
functions from inside inheriting functions.">can-construct-super</a></strong> <small>3.0.0</small> Call can-construct base methods easily
<ul>
<li><code>npm install can-construct-super --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-construct-super" data-count-href="/canjs/can-construct-super/stargazers" data-count-api="/repos/canjs/can-construct-super#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-vdom.html" title="A browser-lite environment for Node.js or a worker thread.">can-vdom</a></strong> <small>3.0.1</small> A virtual DOM that supports can-stache
<ul>
<li><code>npm install can-vdom --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-vdom" data-count-href="/canjs/can-vdom/stargazers" data-count-api="/repos/canjs/can-vdom#stargazers_count">Star</a></li>
</ul></li>
</ul>
</div>
<h3><a href="doc/can-infrastructure.html" title="Utility libraries that power the core and ecosystem collection.">Infrastructure Collection</a></h3>
<p><em>Utility libraries that power the core collection.</em></p>
<div class="module-list">
<ul>
<li><strong><a href="doc/can-event.html" title="Add event functionality into your objects.
The canEvent object provides a number of methods for handling events in objects. This functionality is best used by mixing the canEvent object into an object or prototype. However, event listeners can still be used even on objects that don't include canEvent.
All methods provided by canEvent assume that they are mixed into an object -- this should be the object dispatching the events.">can-event</a></strong> <small>3.0.1</small> Event mixin
<ul>
<li><code>npm install can-event --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-event" data-count-href="/canjs/can-event/stargazers" data-count-api="/repos/canjs/can-event#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-control.html" title="Create organized, memory-leak free, rapidly performing, stateful controls with declarative event binding. Use Control to create UI
controls like tabs, grids, and context menus,
and organize them into higher-order business rules with
can.route. It can serve as both a traditional view and a traditional controller.">can-control</a></strong> <small>3.0.3</small> DOM widget constructor
<ul>
<li><code>npm install can-control --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-control" data-count-href="/canjs/can-control/stargazers" data-count-api="/repos/canjs/can-control#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-util.html" title="A set of utilities.">can-util</a></strong> <small>3.0.11</small> Low level JS and DOM utilities
<ul>
<li><code>npm install can-util --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-util" data-count-href="/canjs/can-util/stargazers" data-count-api="/repos/canjs/can-util#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-construct.html" title="Provides a way to easily use the power of prototypal inheritance
without worrying about hooking up all the particulars yourself. Use
can-construct.extend to create an inheritable
constructor function of your own.">can-construct</a></strong> <small>3.0.3</small> Extensible constructors
<ul>
<li><code>npm install can-construct --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-construct" data-count-href="/canjs/can-construct/stargazers" data-count-api="/repos/canjs/can-construct#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-observation.html" title="Provides a mechanism to notify when an observable has been read and a
way to observe those reads called within a given function.">can-observation</a></strong> <small>3.0.2</small> Observation notification
<ul>
<li><code>npm install can-observation --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-observation" data-count-href="/canjs/can-observation/stargazers" data-count-api="/repos/canjs/can-observation#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-simple-map.html" title="A performant live-bound map.">can-simple-map</a></strong> <small></small> Simple observable object
<ul>
<li><code>npm install can-simple-map --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-simple-map" data-count-href="/canjs/can-simple-map/stargazers" data-count-api="/repos/canjs/can-simple-map#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-view-callbacks.html" title="Registered callbacks for behaviors">can-view-callbacks</a></strong> <small>3.0.1</small> Register custom elements or attributes in can-stache
<ul>
<li><code>npm install can-view-callbacks --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-view-callbacks" data-count-href="/canjs/can-view-callbacks/stargazers" data-count-api="/repos/canjs/can-view-callbacks#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-view-model.html" title="Gets the ViewModel of an element.">can-view-model</a></strong> <small>3.0.0</small> Read a view-model from a custom element
<ul>
<li><code>npm install can-view-model --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-view-model" data-count-href="/canjs/can-view-model/stargazers" data-count-api="/repos/canjs/can-view-model#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-view-scope.html" title="Create a lookup node for keys.">can-view-scope</a></strong> <small>3.1.0</small> Scope lookup
<ul>
<li><code>npm install can-view-scope --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-view-scope" data-count-href="/canjs/can-view-scope/stargazers" data-count-api="/repos/canjs/can-view-scope#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-view-parser.html" title="Parse HTML and mustache tokens.">can-view-parser</a></strong> <small>3.0.1</small> Parses HTML and magic tags
<ul>
<li><code>npm install can-view-parser --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-view-parser" data-count-href="/canjs/can-view-parser/stargazers" data-count-api="/repos/canjs/can-view-parser#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-view-target.html" title="">can-view-target</a></strong> <small>3.0.3</small> A fast-path DOM fragment compile target
<ul>
<li><code>npm install can-view-target --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-view-target" data-count-href="/canjs/can-view-target/stargazers" data-count-api="/repos/canjs/can-view-target#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-view-live.html" title="Setup live-binding between the DOM and a compute manually.">can-view-live</a></strong> <small>3.0.1</small> Update the DOM with
a compute
<ul>
<li><code>npm install can-view-live --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-view-live" data-count-href="/canjs/can-view-live/stargazers" data-count-api="/repos/canjs/can-view-live#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-view-nodelist.html" title="Adds nesting of text nodes
can.view.nodeLists are used to make sure "directly nested" live-binding
sections update content correctly.
Consider the following template:
<div>
{{#if items.length}}
Items:
{{#items}}
<label></label>
{{/items}}
{{/if}}
</div>
The {{#if}} and {{#items}} seconds are "directly nested" because
they share the same <div> parent element.
If {{#items}} changes the DOM by adding more <labels>,
{{#if}} needs to know about the <labels> to remove them
if {{#if}} is re-rendered. {{#if}} would be re-rendered, for example, if
all items were removed.">can-view-nodelist</a></strong> <small>3.0.1</small> Maintains live-binding relationships
<ul>
<li><code>npm install can-view-nodelist --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-view-nodelist" data-count-href="/canjs/can-view-nodelist/stargazers" data-count-api="/repos/canjs/can-view-nodelist#stargazers_count">Star</a></li>
</ul></li>
</ul>
</div>
<h3><a href="doc/can-legacy.html" title="Former libraries that we still accept patches for, but are not under active development.">Legacy Collection</a></h3>
<p><em>Former libraries that are not under active development, but we
still accept patches.</em></p>
<div class="module-list">
<ul>
<li><strong><a href="doc/can-map.html" title="Create observable objects.">can-map</a></strong> <small>3.0.2</small> Observable map
<ul>
<li><code>npm install can-map --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-map" data-count-href="/canjs/can-map/stargazers" data-count-api="/repos/canjs/can-map#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-list.html" title="">can-list</a></strong> <small>3.0.0</small> Observable lists
<ul>
<li><code>npm install can-list --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-list" data-count-href="/canjs/can-list/stargazers" data-count-api="/repos/canjs/can-list#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-map-define.html" title="Defines the
type, initial value, get, set, remove, and serialize behavior for attributes
of a Map.">can-map-define</a></strong> <small>3.0.0</small> Define property behavior
<ul>
<li><code>npm install can-map-define --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-map-define" data-count-href="/canjs/can-map-define/stargazers" data-count-api="/repos/canjs/can-map-define#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-map-backup.html" title="">can-map-backup</a></strong> <small>3.0.0</small> Save the last state
<ul>
<li><code>npm install can-map-backup --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-map-backup" data-count-href="/canjs/can-map-backup/stargazers" data-count-api="/repos/canjs/can-map-backup#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-ejs.html" title="EJS provides live ERB-style client-side templates.">can-ejs</a></strong> <small>3.0.0</small> EJS templates
<ul>
<li><code>npm install can-ejs --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-ejs" data-count-href="/canjs/can-ejs/stargazers" data-count-api="/repos/canjs/can-ejs#stargazers_count">Star</a></li>
</ul></li>
<li><strong><a href="doc/can-view-href.html" title="Sets an element's href attribute so that it's url will set the specified attribute values on can-route.">can-view-href</a></strong> <small>3.0.1</small> Older routing view helpers
<ul>
<li><code>npm install can-view-href --save</code></li>
<li><a class="github-button" href="https://github.com/canjs/can-view-href" data-count-href="/canjs/can-view-href/stargazers" data-count-api="/repos/canjs/can-view-href#stargazers_count">Star</a></li>
</ul></li>
</ul>
</div>
<h2>Missing Something?</h2>
<p>Is there an itch that CanJS doesn't scratch? Let us know
on <a href="https://gitter.im/canjs/canjs">gitter chat</a> or the <a href="http://forums.donejs.com/c/canjs">forums</a>.
We like contributions of all sorts. Read the <a href="doc/guides.html" title="Welcome to CanJS! These guides are here to help you develop and improve your relationship with CanJS. After all, picking a JavaScript framework is a commitment. We want CanJS to be the
framework you marry. This page helps you know how advance through the different stages of this
relationship:">Guides</a> <em>Contributing</em> section for more details.</p>
<h2>Love Something?</h2>
<p>Let us know by staring us on Github and following on twitter. If there's a particular package you like, make sure to star that too. Checkout the <a href="doc/guides/contributing/evangelism.html" title="Learn about resources that can help you spread the word about CanJS.">Evangelism Guide</a> on
how to help spread the word!</p>
</section>
<script type="text/javascript">
var docObject = {"src":{"path":"docs/can-canjs/canjs.md"},"description":"CanJS is an evolving and improving set of client side JavaScript architectural libraries that balances\ninnovation and stability. It targets experienced developers building complex applications with long futures ahead of them.\n\n<img\n srcset=\"docs/images/home/Home-Tortoise-color.png 1x, docs/images/home/Home-Tortoise-bw-x2.png 2x\"\n src=\"docs/images/home/Home-Tortoise-color.png\"\n style=\"float:right; padding-right: 40px;\"/>\n<img\n srcset=\"docs/images/home/Home-Hare-color.png 1x, docs/images/home/Home-Hare-bw-x2.png 2x\"\n src=\"docs/images/home/Home-Tortoise-color.png\" style=\"padding-left: 40px;\"/>\n\nIf you're new to the framework, the best place to start is the [guides] page. There you'll\nfind CanJS's [guides/mission Mission], [guides/technical Technical Highlights] and\nthe [guides/chat Chat], [guides/todomvc TodoMVC], and [guides/atm ATM] guide.\n\n","name":"canjs","title":"CanJS","type":"page","dest":"../index","outline":"0","package":{"name":"can","version":"3.0.0","main":"can.js","scripts":{"preversion":"npm test","version":"git commit -am \"Update dist for release\" && git checkout -b release && git add -f dist/","postversion":"git push --tags && git checkout master && git branch -D release && git push","testee":"testee test/index.html --browsers firefox","testee-production":"testee test/production.html --browsers firefox","http-server":"http-server -p 3000 --silent","test":"npm run test-development && npm run test-production ","test-development":"npm run build && npm run testee","test-production":"npm run build && npm run build-tests && npm run testee-production","ci":"npm run build && node test/test-sauce-labs.js","release:pre":"npm version prerelease && npm run build && npm publish","release:patch":"npm version patch && npm run build && npm publish","release:minor":"npm version minor && npm run build && npm publish","release:major":"npm version major && npm run build && npm publish","build":"node build.js","build-tests":"node test/build.js","document":"bit-docs"},"title":"CanJS","description":"MIT-licensed, client-side, JavaScript framework that makes building rich web applications easy.","keywords":["CanJS","DoneJS"],"author":{"name":"Bitovi","email":"contact@bitovi.com","web":"http://bitovi.com/"},"homepage":"http://canjs.com/","repository":{"type":"git","url":"git@github.com:canjs/canjs.git","github":"https://github.com/canjs/canjs"},"dependencies":{"can-component":"3.0.2","can-compute":"3.0.3","can-connect":"1.0.11","can-construct":"3.0.3","can-construct-super":"3.0.0","can-control":"3.0.3","can-define":"1.0.4","can-define-stream":"0.0.2","can-ejs":"3.0.0","can-event":"3.0.1","can-fixture":"1.0.7","can-fixture-socket":"^0.5.7","can-jquery":"3.0.2","can-list":"3.0.0","can-map":"3.0.2","can-map-backup":"3.0.0","can-map-define":"3.0.0","can-observation":"3.0.2","can-route":"3.0.3","can-route-pushstate":"3.0.0","can-set":"1.0.2","can-simple-dom":"1.0.2","can-simple-map":"3.0.1","can-stache":"3.0.7","can-stache-bindings":"3.0.4","can-stache-converters":"3.0.3","can-stream":"0.0.5","can-util":"3.0.11","can-vdom":"3.0.1","can-view-autorender":"3.0.1","can-view-callbacks":"3.0.1","can-view-href":"3.0.1","can-view-import":"3.0.1","can-view-live":"3.0.1","can-view-model":"3.0.0","can-view-nodelist":"3.0.1","can-view-parser":"3.0.1","can-view-scope":"3.0.1","can-view-target":"3.0.3","can-zone":"0.6.0"},"devDependencies":{"async":"^2.1.2","bit-docs":"^0.0.7","funcunit":"^3.1.0-pre.1","http-server":"^0.9.0","jquery":"^2.2.3","jquery-ui":"^1.12.0","saucelabs":"^1.3.0","socket.io-client":"^1.5.1","steal":"^0.16.4","steal-qunit":"^0.1.1","steal-stache":"^3.0.1","steal-tools":"pre","testee":"^0.2.5","wd":"^1.0.0"},"demos":["http://canjs.us/#examples","http://canjs.us/recipes"],"googleAnalyticsTrackingCode":"UA-2302003-11","licenses":[{"type":"MIT","url":"http://opensource.org/licenses/mit-license.php"}],"system":{"npmAlgorithm":"flat","main":"can","npmIgnore":["bit-docs","testee","async","saucelabs","wd","http-server"]},"bit-docs":{"dependencies":{"bit-docs-glob-finder":"^0.0.5","bit-docs-dev":"^0.0.3","bit-docs-js":"^0.0.6","bit-docs-tag-sourceref":"^0.0.3","bit-docs-generate-html":"^0.3.0","bit-docs-html-canjs":"^0.4.6","bit-docs-prettify":"^0.1.1","bit-docs-html-highlight-line":"^0.2.2","bit-docs-tag-demo":"^0.3.0","bit-docs-tag-package":"^0.0.3"},"glob":{"pattern":"{node_modules,docs}/{can-*,steal-stache}/**/*.{js,md}","ignore":["node_modules/can-wait/examples/**/*","node_modules/can-*/dist/**/*"]},"altVersions":{"2.3.27":"https://v2.canjs.com"},"parent":"canjs","minifyBuild":false}},"templateRender":["<%","%>"],"comment":" ","pathToRoot":""};
</script>
</article>
<footer><p>CanJS is part of <a href="http://donejs.com" target="_blank">DoneJS</a>. Created and maintained by the core <a href="https://donejs.com/About.html#section=section_Team" target="_blank">DoneJS team</a> and <a href="http://bitovi.com" target="_blank">Bitovi</a>. <strong>Currently 3.0.0.</strong></p></footer>
</div>
</div>
</div>
<script>
steal = {
instantiated: {
"bundles/bit-docs-site/static.css!$css" : null
}
};
</script>
<script type='text/javascript' data-main="bit-docs-site/static" src="doc/static/node_modules/steal/steal.production.js"></script>
<script async defer src="https://buttons.github.io/buttons.js"></script>
</body>
</html>