├── .editorconfig ├── .gitignore ├── .jshintrc ├── .npmignore ├── .travis.yml ├── CHANGELOG.md ├── NOTES.md ├── README.md ├── bower.json ├── component.json ├── dist ├── ractive-adaptors-backbone.js └── ractive-adaptors-backbone.min.js ├── gobblefile.js ├── package.json ├── src └── ractive-adaptors-backbone.js ├── test └── test.js └── vendor ├── backbone ├── backbone-1.0.0.js └── backbone-1.1.2.js └── ractive ├── ractive-0.4.0.js ├── ractive-0.5.0.js ├── ractive-0.5.8.js ├── ractive-0.6.0.js └── ractive-0.7.2.js /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | indent_style = tab 5 | end_of_line = lf 6 | insert_final_newline = true 7 | 8 | [*.js] 9 | ; npmjs.org/package/codepainter 10 | quote_type = single 11 | space_after_anonymous_functions = true 12 | space_after_control_statements = true 13 | spaces_around_operators = true 14 | trim_trailing_whitespace = true 15 | spaces_in_brackets = hybrid 16 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .gobble-build 2 | !.gitignore 3 | node_modules/ 4 | tmp/ 5 | coverage.html 6 | -------------------------------------------------------------------------------- /.jshintrc: -------------------------------------------------------------------------------- 1 | { 2 | "esnext": true, 3 | "undef": true, 4 | "unused": true, 5 | "globals": { 6 | "window": true 7 | } 8 | } -------------------------------------------------------------------------------- /.npmignore: -------------------------------------------------------------------------------- 1 | test 2 | vendor 3 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: node_js 2 | node_js: 3 | - "0.10" 4 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | ## v0.3.0 - April 6, 2015 2 | 3 | * Adaptor no longer self-registers in a module environment, and no longer has a dependency on Ractive or Backbone (@rich-harris, #31) 4 | 5 | * Internal: Rewrote as ES6 module (@rich-harris, #31) 6 | 7 | ## v0.2.0 - October 4, 2014 8 | 9 | This release brings better compatibility with Ractive 0.6.x and Backbone 1.1.x. 10 | 11 | * Fix infinite loop issue that arises when one model is wrapped twice. 12 | (@anton-ryzhov, #21) 13 | 14 | * Fix nested collections support. (#13) 15 | 16 | * Internal: update test suite to Mocha. (@rstacruz, #17, #18) 17 | 18 | * Internal: remove Grunt dependency. (@rstacruz, #25, #26) 19 | 20 | * List Backbone and Ractive as peer dependencies. (@rstacruz, #19) 21 | 22 | * Update required versions of Backbone and Ractive to allow future versions. 23 | (@rstacruz, #19) 24 | 25 | * Use Backbone's `model.set` instead of `model.reset`. Fixes Backbone 1.1.2 26 | support. (@browniefed, #12, #10) 27 | 28 | ## v0.1.1 - June 9, 2014 29 | 30 | * BREAKING CHANGE: Rename to `ractive-adaptors-backbone`. 31 | 32 | * Fix `reset` issue when performing `set('model', null)`. (@bartsqueezy, #3) 33 | 34 | * Fix browserify compatibility. (@ahdinosaur, #1) 35 | 36 | ## v0.1.0 - October 30, 2013 37 | 38 | * Initial release as `ractive-backbone`. 39 | -------------------------------------------------------------------------------- /NOTES.md: -------------------------------------------------------------------------------- 1 | Developer notes 2 | =============== 3 | 4 | Testing: 5 | 6 | npm test 7 | 8 | Building .min.js: 9 | 10 | npm run prepublish 11 | 12 | Releasing new versions: 13 | 14 | # update version numbers 15 | bump *.json *bone.js 16 | 17 | # update changelog with date 18 | vim CHANGELOG.md 19 | 20 | # test 21 | npm test 22 | 23 | # publish to npm (this will already build .min) 24 | npm publish 25 | 26 | git release v1.0.0 27 | 28 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # ractive-adaptors-backbone 2 | 3 | Use Backbone models and collections in your [Ractive] components.
4 | **[View demo ›][Example]** 5 | 6 | [![Status](http://img.shields.io/travis/ractivejs/ractive-adaptors-backbone/master.svg?style=flat)](https://travis-ci.org/ractivejs/ractive-adaptors-backbone "See test builds") 7 | 8 | *Find more Ractive.js plugins at 9 | [docs.ractivejs.org/latest/plugins](http://docs.ractivejs.org/latest/plugins)* 10 | 11 | ## Installation 12 | 13 | Include `ractive-adaptors-backbone.min.js` on your page below Ractive, e.g: 14 | 15 | ```html 16 | 17 | 18 | ``` 19 | 20 | To get ractive-adaptors-backbone you can: 21 | 22 | #### Use CDN 23 | 24 | https://cdn.jsdelivr.net/npm/ractive-adaptors-backbone@0.3.0/dist/ractive-adaptors-backbone.min.js 25 | 26 | #### Use bower 27 | 28 | $ bower i ractive-adaptors-backbone 29 | 30 | #### Use npm 31 | 32 | $ npm install --save ractive-adaptors-backbone 33 | 34 | #### Download 35 | 36 | - [Download the latest release](https://github.com/ractivejs/ractive-adaptors-backbone/releases). 37 | 38 | ## Usage 39 | 40 | If you're using `