[Pkg-javascript-commits] [backbone] 272/281: adding a section to the Backbone FAQ on extending...
Jonas Smedegaard
js at moszumanska.debian.org
Sat May 3 17:02:21 UTC 2014
This is an automated email from the git hooks/post-receive script.
js pushed a commit to tag 0.9.0
in repository backbone.
commit a2ab3b13eb18c5488b2521aa6e21d4c197889442
Author: Jeremy Ashkenas <jashkenas at gmail.com>
Date: Mon Jan 30 11:40:35 2012 -0500
adding a section to the Backbone FAQ on extending...
---
index.html | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/index.html b/index.html
index 15df8eb..d5ce9dc 100644
--- a/index.html
+++ b/index.html
@@ -363,6 +363,7 @@
<li>– <a href="#FAQ-tim-toady">More Than One Way To Do It</a></li>
<li>– <a href="#FAQ-nested">Nested Models & Collections</a></li>
<li>– <a href="#FAQ-bootstrap">Loading Bootstrapped Models</a></li>
+ <li>– <a href="#FAQ-extending">Extending Backbone</a></li>
<li>– <a href="#FAQ-mvc">Traditional MVC</a></li>
<li>– <a href="#FAQ-this">Binding "this"</a></li>
<li>– <a href="#FAQ-rails">Working with Rails</a></li>
@@ -2890,6 +2891,25 @@ Inbox.messages.fetch();
</script>
</pre>
+ <p id="FAQ-extending">
+ <b class="header">Extending Backbone</b>
+ <br />
+ Many JavaScript libraries are meant to be insular and self-enclosed,
+ where you interact with them by calling their public API, but never peek
+ inside at the guts. Backbone.js is <i>not</i> that kind of library.
+ </p>
+
+ <p>
+ Because it serves as a foundation for your application, you're meant to
+ extend and enhance it in the ways you see fit — the entire source
+ code is <a href="docs/backbone.html">annotated</a> to make this easier
+ for you. You'll find that there's very little there apart from core
+ functions, and most of those can be overriden or augmented should you find
+ the need. If you catch yourself adding methods to <tt>Backbone.Model.prototype</tt>,
+ or creating your own base subclass, don't worry — that's how things are
+ supposed to work.
+ </p>
+
<p id="FAQ-mvc">
<b class="header">How does Backbone relate to "traditional" MVC?</b>
<br />
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/backbone.git
More information about the Pkg-javascript-commits
mailing list