Skip to content

Commit 95f7d09

Browse files
author
Vlad Balin
committed
Release
1 parent 8ddc420 commit 95f7d09

File tree

8 files changed

+30
-199
lines changed

8 files changed

+30
-199
lines changed

README.md

+10-11
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,21 @@
1-
NestedTypes 2.0 will become BackboneJS compatibility layer for the Type-R.
2-
Type-R is written from the scratch with the TypeScript and contains no Backbone legacy.
1+
NestedTypes 2.0 is BackboneJS compatibility layer for the [Type-R](https://volicon.github.io/Type-R/Getting_Started.html) data-layer framework.
2+
Type-R is Model/Collection core written from the scratch with the TypeScript and has no side dependencies.
33

4-
Documentation update pending. Don't try 2.0rc unless you know what you're doing. 2.0rc is used Volicon's internal integration.
4+
NestedTypes adds support for REST (standard BackboneJS API), Underscore methods, and Backbone 1.1 classes.
55

6-
# NestedTypes 2.0 model framework
6+
> If you're upgrading from the version 1.3, *[there are compatibility issues](/docs/compatibility.md)*.
7+
> Mostly due to the fact that the Type-R and NestedTypes 2.0 is built around the concept of [aggregation trees](https://volicon.github.io/Type-R/API_by_feature/Aggregation_tree.html).
8+
> NestedTypes 1.3 code won't work without refactoring.
9+
10+
# NestedTypes 2.0 new features
711

812
Post-backbone data framework. 10 times faster, first-class support for nested models and collections and relations by id.
913

1014
- ES6 classes support.
1115
- Deeply observable changes.
12-
- Aggregated records and collections.
13-
- First-class support for [relations by id](/docs/RelationsGuide.md).
16+
- First-class support for [aggregation](https://volicon.github.io/Type-R/API_by_feature/Aggregation_tree.html) and [relations by id](https://volicon.github.io/Type-R/API_by_feature/id-references_and_Stores.html).
1417
- Attribute type annotations and dynamic type safety.
15-
- About 10 times faster than BackboneJS and 2-4 times faster than NestedTypes 1.3 in all browsers.
16-
- Backward compatible with the majority of [BackboneJS API](http://backbonejs.org/). Although, [it's conceptually different](/docs/BackboneTransitionGuide.md).
17-
18-
> If you're upgrading from the version 1.3, *[there are compatibility issues](/docs/compatibility.md)*.
19-
> NestedTypes 1.3 code won't work without refactoring.
18+
- More than 10 times faster than BackboneJS and 2-4 times faster than NestedTypes 1.3 in all browsers.
2019

2120
# Installation & Requirements
2221

dist/index.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/index.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/compatibility.md

+16-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,22 @@ Because of that, NestedTypes 1.3 code will not work without modifications.
55

66
### Refactoring Guide
77

8-
TBD
8+
## Watch out for aggregation errors!
9+
10+
Read the [Type-R documentation](https://volicon.github.io/Type-R/API_by_feature/Aggregation_tree.html) about aggregation and shared references.
11+
12+
The majority of the refactoring required is adding `Model.shared` and `Collection.Refs` in places where the UI state has references to shared objects.
13+
14+
Errors will appear when you are trying to assign parts of one aggregation tree to another. They will look like this:
15+
16+
`[Model Update] Aggregated 'User.name : ModelType' attribute is assigned with an object which is aggregated somewhere else.`
17+
18+
`[Model Update] Aggregated 'User.name : CollectionType' attribute is assigned with a shared Collection.Set.`
19+
20+
`[Collection Update] Aggregating [[ Model.name : ] CollectionType ] collection is updated with models which are aggregated somewhere else.`
21+
22+
## Old API Deprecations
23+
- `modelOrCollection.clone()` now performs deep cloning. `modelOrCollection.deepClone()` is deprecated.
924

1025
### API changes
1126

docs/hardrefs.md

-13
This file was deleted.

docs/stores.md

-170
This file was deleted.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "nestedtypes",
3-
"version": "2.0.0-rc995",
3+
"version": "2.0.0",
44
"main": "./dist/index.js",
55
"module": "./lib/index.js",
66
"types": "./lib/index.d.ts",

submodules/Type-R

Submodule Type-R updated 93 files

0 commit comments

Comments
 (0)