{"id":17109570,"url":"https://github.com/monken/js-geraldine","last_synced_at":"2025-03-23T21:41:33.205Z","repository":{"id":32981689,"uuid":"36606595","full_name":"monken/js-geraldine","owner":"monken","description":null,"archived":false,"fork":false,"pushed_at":"2017-03-10T01:14:57.000Z","size":19,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-01T03:25:00.293Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/monken.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-05-31T14:28:22.000Z","updated_at":"2017-03-10T01:14:59.000Z","dependencies_parsed_at":"2022-08-31T00:01:33.650Z","dependency_job_id":null,"html_url":"https://github.com/monken/js-geraldine","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/monken%2Fjs-geraldine","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/monken%2Fjs-geraldine/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/monken%2Fjs-geraldine/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/monken%2Fjs-geraldine/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/monken","download_url":"https://codeload.github.com/monken/js-geraldine/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245175323,"owners_count":20572781,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-14T16:23:38.370Z","updated_at":"2025-03-23T21:41:33.184Z","avatar_url":"https://github.com/monken.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Build Status](https://travis-ci.org/monken/js-geraldine.svg?branch=master)](https://travis-ci.org/monken/js-geraldine)\n\n# js-geraldine\n\nSome improvements to [Chaplin](http://chaplinjs.org/) and [Backbone.JS](http://backbonejs.org/).\n\n\u003c!-- START doctoc generated TOC please keep comment here to allow auto update --\u003e\n\u003c!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE --\u003e\nContents\n\n- [Global](#global)\n  - [Class: Collection](#class-collection)\n    - [Collection.setActive(model, [options])](#collectionsetactivemodel-options)\n    - [Collection.getActive()](#collectiongetactive)\n    - [Collection.getLast()](#collectiongetlast)\n    - [Collection.save()](#collectionsave)\n    - [Collection.deepClone()](#collectiondeepclone)\n- [Global](#global-1)\n  - [Class: View](#class-view)\n\n\u003c!-- END doctoc generated TOC please keep comment here to allow auto update --\u003e\n# Global\n\n\n\n\n\n* * *\n\n## Class: Collection\n\n\n### Collection.setActive(model, [options]) \n\nUnsets the `activeAttribute` attribute on all models and sets it on the `model` passed as first argument.\nTriggers the `active` event with the `model` passed as first parameter.\n\n**Parameters**\n\n**model**: `Model`, Model that is set to active\n\n**[options]**: `Object`, Options that are passed to `set` such as `{ silent: true }`\n\n**Returns**: `Model`\n\n### Collection.getActive() \n\nReturns the (first) `active` model or `null` if there are no active models.\n\n**Returns**: `Model`\n\n### Collection.getLast() \n\nReturns the last model in the collection.\n\n**Returns**: `Model`\n\n### Collection.save() \n\nInvoke `save` on all models of the collection.\n\n**Returns**: `Models`\n\n### Collection.deepClone() \n\nCreates a clone of the collection by copying the models in a new array.\nChanges to the new collection will not affect the original collection.\n\n**Returns**: `Collection`\n\n\n\n* * *\n\n\n\n\n\n\n\n\n\n\n# Global\n\n\n\n\n\n* * *\n\n## Class: View\n\n\n**bindings**: `Object` , The `bindings` attribute defines data bindings to html elements. Bindings can contain\na transformation function to modify the original value. Bindings also work for relationship\nattributes. If the relationship is a collection, the element will be updated if any of the\nadd, remove or reset events are triggered on the collection.\n\nBindings will be initialized when the view is rendered.\n\n```\nView.extend({\n  bindings: {\n    // bind name attribute to content of element with class 'name'\n    '.name': 'name',\n    // format 'dateOfBirth' attribute\n    '.born': ['dateOfBirth', function(value) { return moment(value).format('ll') }],\n    // update count of children\n    '.children': ['children', function(value) { return children.length }],\n  }\n});\n```\n\n\n* * *\n\n\n\n\n\n\n\n\n\n\nThe MIT License (MIT)\n\nCopyright (c) 2015 Moritz Onken\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmonken%2Fjs-geraldine","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmonken%2Fjs-geraldine","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmonken%2Fjs-geraldine/lists"}