Commit Graph

3408 Commits

Author SHA1 Message Date
Alexey
a2f7cbafd3 Fix env vars 2022-01-21 23:20:25 +03:00
Alexey
52f23814f7 Add workflows to paths 2022-01-21 21:30:44 +03:00
Alexey
17018ebdc7 Replace branches list 2022-01-21 21:28:24 +03:00
Julian Gonggrijp
589f1b97b3 Credit Sauce Labs in the README (#4247) 2022-01-21 14:06:23 +01:00
Julian Gonggrijp
b7bd1706e6 Merge pull request #4248 from ogonkov/gh_workflows
Replace Travis with GitHub Workflows
2022-01-21 14:00:21 +01:00
Alexey
5d95c0afdf Cache deps 2022-01-18 17:38:22 +03:00
Alexey
27c9159b88 Use --no-audit for install 2022-01-18 17:36:49 +03:00
Alexey
8a9fe59c3e Add --no-audit flag 2022-01-18 12:53:56 +03:00
Alexey
e7ba250be6 Fix module installation 2022-01-18 12:52:27 +03:00
Alexey
0738170a23 Add job name 2022-01-18 12:35:38 +03:00
Alexey
9e2df5cd4a Remove .travis.yml 2022-01-18 12:35:38 +03:00
Alexey
84306a51e3 Remove unused selector 2022-01-18 12:35:38 +03:00
Alexey
0a66d8ce90 Lint karma.conf-sauce.js 2022-01-18 12:35:38 +03:00
Alexey
723dd48942 Add GitHub Workflows 2022-01-18 12:35:38 +03:00
Julian Gonggrijp
5147eca76f Merge pull request #4249 from jashkenas/byid-when-if-change
Add model changeId event
2022-01-12 15:46:31 +01:00
Paul Falgout
7712b8ec6c Add model changeId event
Fixes #3882
Fixes #4159

Backbone does a bit of extra work to determine when to update `_byId` on every model change event because `change:id` will not work if `idAttribute` has changed.  This causes issues as the `change` event happens after every `change:` event which means during a change the `_byId` hasn't updated.  Rather than adding complexity to collection the solution is to have the model notify with the id changes.

If adding a public event isn't desired, for an internal solution the model is aware of it's collection and could modify model.collection._byId directly within the set.

Either of these solutions seem preferrable to handling `change:[idAttribute]`

Replaces the need for:
https://github.com/jashkenas/backbone/pull/4227/files#diff-c773bb9be277f0f3f2baa308b6e0f3a486790fe99fea81ddd0ba409846250571R1205
2022-01-12 23:26:10 +09:00
Julian Gonggrijp
a9894e03c4 Merge pull request #4234 from ogonkov/fix_model_instantiation
Add check for `this.model.prototype`
2022-01-09 22:34:24 +01:00
Alexey
2ea3a221ad Remove try..catch 2022-01-09 20:17:55 +03:00
Alexey
e54031f227 Return function 2022-01-09 20:14:20 +03:00
Alexey
4515b8c20a Fix synatx error 2022-01-09 20:13:45 +03:00
Alexey
f6f5deeae9 Add test 2022-01-08 12:42:00 +03:00
Jeremy Ashkenas
153dc41616 Merge pull request #4238 from binlabs/patch-1
Added missing parenthesis in the Collection preinitialize code example
2020-05-04 10:58:14 -07:00
Kurt Maine
22f157afc3 Added missing parenthesis in the Collection preinitialize code example
The event listener was missing a closing parenthesis in the preinitialize code sample for Collections.
2020-04-01 21:48:34 -05:00
Alexey
1fce745d77 Add check for this.model.prototype 2020-03-03 20:50:16 +03:00
jashkenas
0b1c2e3fce Resolve merge conflicts 2019-12-13 11:41:21 -08:00
jashkenas
75e6d0ce63 Missing a few version 1.4.0s 2019-02-19 10:35:53 -08:00
jashkenas
afbb6ee089 Merged in 1.4.0 2019-02-19 10:34:22 -08:00
jashkenas
5de45fc9e1 Backbone 1.4.0 1.4.0 2019-02-19 10:29:40 -08:00
jashkenas
c336c8a056 Allow ESLint to do its thing. 2019-02-19 09:47:24 -08:00
Jeremy Ashkenas
77da9aeccb Create CNAME 2018-05-07 10:41:08 -07:00
Jeremy Ashkenas
af0179cf61 Delete CNAME 2018-05-07 10:41:03 -07:00
Jeremy Ashkenas
27f7d41de1 Merge pull request #4190 from AndresArturo/4189
Mention use of Options on Collection#model handling of Model instantiations
2018-04-09 11:26:18 -07:00
Andrés Arturo
594bf08c7c Mention Options to be passed down from Collection on Model creation 2018-04-08 06:47:51 +02:00
Jeremy Ashkenas
82bf61e00d Merge pull request #4146 from rafde/lodash5-compat
`_.bind` to `Function.prototype.bind`
2017-12-05 11:21:48 -08:00
jashkenas
06fd17a39d Fixes #4149, xhr passed to error event, not response 2017-12-05 11:15:46 -08:00
Jeremy Ashkenas
6e707b3e3f Merge pull request #4163 from AndresArturo/model-isvalid-docs
Clarify documentation of Model#isValid and Model#validate
2017-12-05 11:08:39 -08:00
schweickism
e6e71f447c Clarify misleading line in docs: comparator only executes on add or sort (#4150) 2017-12-04 21:34:52 +01:00
Andrés Arturo
47955c05b8 Include a description of the events triggered in Model#isValid in the docs 2017-09-30 19:03:46 +02:00
Rafael De Leon
678aeee94d update travis ci to use node 6 since it's in LTS (#4147) 2017-08-01 13:25:47 -04:00
Rafael De Leon
2276b8dcf9 _.bind to Function.prototype.bind 2017-06-21 22:48:32 -07:00
Graeme Yeates
0eca92f441 Add documentation for Collection#mixin 2017-05-16 16:56:32 -04:00
Graeme Yeates
81f5d1a809 Merge #4134 into Changelog 1.4
* pr/4134:
  Fix minor changes
  Change funcName: function() -> funcName(), ES6 -> ES2015
  Fix typos, change example
  Better examples for preinitialize of Model and Collection
  Fix grammar
  Address comments.
  Fix syntax.
  Update change-log, Add preinitialize method example section for Model/Collection/Router/View
  Add Changelog
2017-05-16 16:33:02 -04:00
sajib
0fb9fda15d Fix minor changes 2017-05-02 11:07:38 +06:00
Jordan Eldredge
a0825c77ac Clarifying improvements to router documentation (#4137)
* Improve documentation of what router actions are passed

* Clarify that actions are functions (as opposed to events)
2017-05-01 17:13:27 -04:00
Jordan Eldredge
09cb8871d8 Clarifying improvements to router documentation (#4137)
* Improve documentation of what router actions are passed

* Clarify that actions are functions (as opposed to events)
2017-05-01 17:10:37 -04:00
sajib
fdd6f8ef4d Change funcName: function() -> funcName(), ES6 -> ES2015 2017-04-26 21:30:10 +06:00
sajib
3c282b5289 Fix typos, change example 2017-04-22 15:23:38 +06:00
sajib
3c52367cf2 Better examples for preinitialize of Model and Collection 2017-04-21 13:05:54 +06:00
Graeme Yeates
e524804592 Implement Model.mixin and Collection.mixin (#4024)
Combine implementation of collection and model underscore methods
2017-04-18 15:29:55 -07:00
tamal
f72d1cabd8 Fix grammar 2017-04-18 14:59:00 -07:00