- Updated dependencies and locked Backbone to 1.1.2
- Removed
thenmethod, if you want to use promises, call.promise().then
- Adds in a
cleanupevent whenever a view has been removed - Fully support & test against LoDash 3.0 and Underscore
- Full Browserify support.
- The options object is now cloned when passed into a Layout.
- Fixes a bug with
setViewremoving deeply nested views. - Fixes compatibility with Backbone Epoxy.
- Fixes a bug where a removed view could still be rendered asynchronously.
renderViewsnow accepts an array of Views to render batched.- Added an
emptyevent that triggers when all Views are removed from a parent.
- Removed
partialshim from Node compatibility layer. No longer necessary. - Removed
getAllOptions, no longer necessary with 1.1.0. - Now run our tests against the latest stable and unstable Node.js.
setViewwill never render a View now.- Broke out Grunt tasks into separate files.
- Enforcing code style with JSCS.
- Fixed trimming for incoming templates so that multiple top level elements warning isn't triggered annoyingly.
- Upgraded to work with Backbone 1.1.0.
- Minor housekeeping commits.
- Style/spelling updates to markdown files.
- Broke out
_viewRenderand_applyTemplatefrom their closures and exposed them on the LM object. - Parsing with
$.parseHTMLto allow leading whitespace and retain whitespace in templates. - Using Bower to manage testing depenencies.
- Fixes for Underscore 1.5.
- Updated AMD define shim to use UMD which fixes issues in some R.js builds.
- Updated views property to accept functions that return values, see #367.
- Fixed Node.js file lookup that was scoping to
__dirname. - Ensured all examples work.
- Hooked up Coveralls for monitoring and displaying code coverage during builds.
- Fixed regression from 0.8->0.9 where the new AMD wrapper would fail to work correctly in an r.js build.
- Fixed regression from 0.8->0.9 where the Node.js branch code was not updated
correctly and lack of default
fetchTemplatetests didn't report the failure.
- Upgraded all internal dependencies.
- Batch rendering via jQuery collections has been added. Check out the
htmlBatchmethod. - Full on AMD support. No more shimming necessary!
rendernow returns the View instance to maintain parity with otherBackbone.Viewtutorials and plugins.fetchandrenderoverrides have been renamed tofetchTemplateandrenderTemplaterespectively.- New method
renderViewswhich will only render nested Views and not the parent view, useful for top level layouts. - Event bubbling has been removed.
- Named regions for selectors using the
sectionobject. - Greatly refactored how the
async()methods work. This allows every method of therenderlifecycle to be asynchronous and maintain the context of the View.
- Upgraded Cheerio dependency to v0.11.0.
- Many optimizations and fixes to
getViewsby @jugglinmike. This includes fixes for issues likeremoveViewon an invalid selector. cleanupis now called with the proper context.- @SBoudrias added
.gitattributesand.editconfigto ease development stress for our contributors. - Fix provided by @adamdicarlo to fix a bug where re-rendering with empty rendered contents would not replace the existing content.
- Upgraded Cheerio dependency.
- Trim templates in
el: falseViews to fix an issue with passing contents into$().
- We now log a warning if you use mutliple top level elements inside a View's
template with
el: false. This will not affect most developers. If you wish to suppress the warnings you can runBackbone.Layout.configure({ suppressWarnings: true });. This is documented in the Wiki: https://github.com/tbranyen/backbone.layoutmanager/wiki/Configuration#el - Fixed minor bug with
cleanupbeing defined onoptionsinstead of the instance. - Changed behavior so that all views are removed when you call
remove. - Upgraded to Backbone 1.0.
- Upgraded to Node 0.10.
- Fixed View duplication bug with multiple top level elements (
el: false). - Fixed the deletion of the template property in initialize that would cause bugs with View inheritance.
- Fixed issue with
getViewand_.whereobject.
- Fixed package dependency issues with jQuery.
- Updated Cheerio version, which includes fixes to
filter. - Several fixes to the
el: falseimplementation. - Removed custom
$.containsNode.js implementation.
- Fix for deep nested
el: falseelements.
- Fixed parts of the Node build.
- Changed from parallel rendering to serial loading which will make the render process significantly more stable.
- Changed signature to
options.partialand greatly fixed the waynoelis handled.
- Updated JamJS configuration settings.
- Fixed event delegation when self managing the View element.
- Fixed edge case with
afterRendercauses the element to not be in the parent container. - Fixed re-rendering when self managing the View element.
- Massive Node.js refactor, including: unit testing, significantly better browser parity, and allowing more seamless browser/server View sharing.
- Ability to disable
Backbone.View#elwrapper element usingel: falseand opt for the first child inside the template instead. Very experimental! - Added Backbone event bubbling from nested Views to parent.
- The
getViewfunction can receive a_.whereobject now, to easily filter through the Views. - Updated
getViewto have anundefinedfirst argument to be passed allowing for an optional selector. - Changed Grunt configuration from JavaScript to CoffeeScript.
- Added a
removeViewfunction to matchsetView,getView, etc. - Removed
LayoutManagerandLayoutViewaliases. - Removed
dataalias in favor ofserialize. - Removed
appendalias in favor ofinsert. - Renamed
_optionstogetAllOptionsmaking it an endorsed method to use. - Upgraded minimum support to Backbone 0.9.9, which will invoke
stopListeningautomatically for you. - Internally using
Backbone.Events#onceto solveafterRenderwoes. - Class method
cachenow allows you to override contents. - Class method
setupViewsnow allows you to manage many Views by passing an array of Views. - Can now directly set a template function to the
templateproperty and not have to override fetch with an_.identityfunction. - Miscellaneous code cleanup and minor bug/refactor fixes.
- Updated lookup for
serializeanddatato also look on the instance so thatconfiguredoesn't always override.
- Simplified insertion methods.
- Fixed named function expression bug in IE.
- Refactored
_.extendtoLayoutManager.augmentto work with Lo-Dash and underscore. - Normalized rendering order, when the parent has already rendered.
- Added better error handling for node.js build.
- Updated error message for node.js build.
- Added in Travis-CI and README updates.
- Fixed cheerio rendering bug with the latest version.
- Explicity depend and require underscore in NPM.
- Repeated subViews are a thing of the past :D.
- Fixed serialize/data priority.
- Fixed lodash issues and added in separate lodash testing.
- Views that have already been rendered can now be inserted into existing Views.
- Fixed the logic that decides when to remove Views.
- Fixed issue with
cleanupnot being on nested Views. - Miscellaneous fixes (inc. null checks, perf. updates, etc).
- Removed minified build file from the repo.
insertViewscan now accept an array of Views.rendercan now be asynchronous to allow template engines like dust.js to work seamlessly, works identical tofetch.- Overriding the template option at initialization level wil now override the constructor option.
- Refactored source to be less cryptic.
- 100% test code coverage.
- Re-wrote much of the internals.
- Performance greatly improved, especially with large lists.
- Removed
swapLayout. serializeis deprecated and replaced bydata.render(callback)is deprecated torender().done()deferreds only.- Automatically unbind
modelandcollectionevents insidecleanup. Backbone.LayoutView,Backbone.Layout, andBackbone.View(withmanageset totrue`) are now all identical.pathsis now a Stringprefix, set this to the folder where your templates live.afterRendernow occurs after therender()deferred.myView.render().viewnow allows you to attachview.elafter a render for some nice one-liners.new Backbone.LayoutView({ template: "#t" }).render().view.$el.appendTo("body");
- Fixed asynchronous fetching bug that could in some circumstances duplicate list items
- Calling
removeon a View now completely removes it from LayoutManager - Fixed issues with
afterRender - Better error handling for when
manage: trueis missing
- Corrected event binding behaviors depending on the parent.
- Fixed regression with
afterRender
- Fixed a memory leak that existed with appended Views
- Updated all examples
- Fixed regression with events being bound to Layouts
- General performance tweaks
- Updated cheerio dependency to 0.9.2 for the Node implementation
- Updated to support jQuery 1.8
- Fixed missing events when calling
view.render - Fixed issues with
afterRendernot triggering - No longer copying options to the View instance
- Patch release fixing issues and upgrading Node.js dependencies
- Fixed error where inserted views rendered out of order #116, #117
- Fixed issue where events were not being bound correctly #118
- Overriding
renderis now deprecated. Refer tobeforeRenderandafterRender. - Added a
swapmethod that can be used on a Layout which allows you to dynamically swap out the entire contents, but retain the rendered subViews. - Code cleanup, removing unused code paths, properties, features, etc.
- Fixes to setView to not break when moving from an append mode to non-append mode.
- Several bug fixes.
- Added more unit tests.
- More methods can be overwritten from initialization
- Render can now be bound like
this.collection.on("reset", this.render, this); - Fixes to
keep: trueand append example, only checkingkeepif View has already rendered
- Patched massive memory leak and missing remove on setView
- Fixed bug with Named Function Expression breaking IE compatibility when minified
- Added
keep: trueto View's to stop them from being removed pre-render
- Tons of new unit tests
- More API normalization
- Collection rendering bug fixes
- New View methods
- insertView & insertViews
- getView and getViews
- Fixed major regression regarding list duplication
- Detach no longer internally happens on the root Layout
managefunction inside a custom render has a new propertyrawfor getting at the actual View instance- Collection lists bugs solved
- Made
makeAsynca private class method - Cleanup method is now called whenever
removeis called - Major fixes allowing for single View append
- View function no longer requires "" for inserting into parent View
- SubView render functions only resolve after the element has been attached to its parent View.
- Context is now consistent in either callbacks or deferreds
setViewsis now chainableviewandsetViewsare now available at all times onBackbone.View's- Bug fixes regarding list duplication
- Made
templateoptional inside ofBackbone.View - Added custom cleanup function to handle the removal of any custom events
- insert no longer requires a selector
- Several performance improvements along with general stability changes
- Major re-write to codebase that eliminated a lot of repetitive and cludgy code
- Deprecated the need to extend
Backbone.LayoutManager.View - All View
rendermethods return promises and can accept a callback - Views now render themselves first and then resolve/trigger the callback once all the children are rendered. This helps with jQuery plugins.
- Major patch for re-rendering layouts that would lose events
- Added new API method detach
- Minor patch release (that removes an undocumented feature)
- Fixed issue with events not being registered correctly within lists
- Lots of bug fixes!
- Ability to insert views dynamically using the new
view.insertmethod. Useful for collections. - Setting/resetting sub views possible with new
view.setViewsmethod. - All views now have the
view/setViewsmethods. - Updates to allow LayoutManager to be extended easier, along with
eventsbeing bound automatically during initialization.
- Adding views turned into a reusable function called
view. - Templates no longer are required to be a string, this allows passing of compiled template functions.
- View renders are internally wrapped to expose a new
render()method that when called, re-renders. - Nested views are possible by adding a
viewssub property which is an object that contains nested views.
- Changed layout
nameproperty totemplatefor consistency. - Internal second deferred replaces the
viewDeferredto determine when an element enters the DOM.
- Open sourced on GitHub.
- Initial unit tests.
- Released introduction screencast.