Skip to content
This repository has been archived by the owner on Feb 22, 2018. It is now read-only.

Observable support in change detection #773

Closed
zoechi opened this issue Mar 20, 2014 · 5 comments
Closed

Observable support in change detection #773

zoechi opened this issue Mar 20, 2014 · 5 comments

Comments

@zoechi
Copy link
Contributor

zoechi commented Mar 20, 2014

There is a lot effort going on to improve performance in Angular and
there are several situations where developers encounter problems (at least negative suprises) because some model changes are not recognized (collections) without some special effort.

Wouldn't it make sense to support something like the observableCollection as it is used in Polymer (https://pub.dartlang.org/packages/observe)? (found the source here https://chromium.googlesource.com/external/dart/+/refs/heads/master/dart/pkg/observe)
I haven't investigated how this works in detail but it is about collections (AFAIK currently only List/Map) that notify about being changed.

This could be extended by defining a pattern how every kind of object can notify Angular about changes by (e.g. implementing an interface ChangeNotifier or whatever).

As a next step I imagine an object using this pattern being able to notify the collection it is stored in about changes and the collection propagates it to parties interested in changes in the collection.

I think this could greatly improve developer experience without to much influence on the performance.

What do you think?

EDIT

seems this already covers this
Layer 1: Object.observe Polyfill

@chalin
Copy link
Contributor

chalin commented Mar 20, 2014

The observe filter (of #771, if/when the PR is merged) may go part way in alleviating the issue you mention.

@zoechi
Copy link
Contributor Author

zoechi commented Mar 20, 2014

Ok then I just close this.

@zoechi zoechi closed this as completed Mar 20, 2014
@chalin
Copy link
Contributor

chalin commented Mar 20, 2014

If observe turns out to be insufficient, please re-open this issue.

@zoechi
Copy link
Contributor Author

zoechi commented Mar 20, 2014

Ok, I will.
Thanks for your feedback!

chalin added a commit to chalin/angular.dart that referenced this issue Mar 20, 2014
@vicb
Copy link
Contributor

vicb commented Jun 2, 2014

I'm starting to work on implementing support for Observable
/cc @jbdeboer

@vicb vicb reopened this Jun 2, 2014
@jbdeboer jbdeboer changed the title Feature request: support for observable Observable support in change detection Jun 8, 2014
vicb added a commit to vicb/angular.dart that referenced this issue Jun 24, 2014
…ifier

Closes dart-archive#773

You should include the following lines in your pubspec.yaml

    dependency_overrides:
      analyzer: '>=0.15.6 <0.16.0'

This is required because the observe package depends on analyzer: '>=0.15.6 <0.16.0'
while all SDK packages have not yet been updated to depends on this version.
vicb added a commit to vicb/angular.dart that referenced this issue Jun 24, 2014
…ifier

Closes dart-archive#773

You should include the following lines in your pubspec.yaml

    dependency_overrides:
      analyzer: '>=0.15.6 <0.16.0'

This is required because the observe package depends on analyzer:
'>=0.15.6 <0.16.0'
while all SDK packages have not yet been updated to depends on this
version.
vicb added a commit to vicb/angular.dart that referenced this issue Jul 24, 2014
…ifier

Closes dart-archive#773

You should include the following lines in your pubspec.yaml

    dependency_overrides:
      analyzer: '>=0.15.6 <0.16.0'

This is required because the observe package depends on analyzer:
'>=0.15.6 <0.16.0'
while all SDK packages have not yet been updated to depends on this
version.
vicb added a commit to vicb/angular.dart that referenced this issue Jul 24, 2014
rkirov pushed a commit to rkirov/angular.dart that referenced this issue Sep 2, 2014
…ifier

Lower the target time to prevent a memory overflow. Benchmark added.

Fixes dart-archive#773
Closes dart-archive#1156
vsavkin pushed a commit to vsavkin/angular.dart that referenced this issue Sep 16, 2014
…ifier

Lower the target time to prevent a memory overflow. Benchmark added.

Fixes dart-archive#773
Closes dart-archive#1156
vsavkin pushed a commit to vsavkin/angular.dart that referenced this issue Sep 16, 2014
…ifier

Lower the target time to prevent a memory overflow. Benchmark added.

Fixes dart-archive#773
Closes dart-archive#1156

Closes dart-archive#1466
rkirov pushed a commit to rkirov/angular.dart that referenced this issue Sep 19, 2014
…ifier

Lower the target time to prevent a memory overflow. Benchmark added.

Fixes dart-archive#773
Closes dart-archive#1156
rkirov pushed a commit to rkirov/angular.dart that referenced this issue Sep 19, 2014
…ifier

Lower the target time to prevent a memory overflow. Benchmark added.

To use annotate your models with @observable or use ObservableList or
ObservableMap.

Fixes dart-archive#773
Closes dart-archive#1156
rkirov pushed a commit to rkirov/angular.dart that referenced this issue Sep 19, 2014
…ifier

Lower the target time to prevent a memory overflow. Benchmark added.

To use annotate your models with @observable or use ObservableList or
ObservableMap.

Fixes dart-archive#773
Closes dart-archive#1156
rkirov pushed a commit to rkirov/angular.dart that referenced this issue Sep 19, 2014
…ifier

Lower the target time to prevent a memory overflow. Benchmark added.

To use annotate your models with @observable or use ObservableList or
ObservableMap.

Fixes dart-archive#773
Closes dart-archive#1156
rkirov pushed a commit to rkirov/angular.dart that referenced this issue Sep 29, 2014
…ifier

Lower the target time to prevent a memory overflow. Benchmark added.

To use annotate your models with @observable or use ObservableList or
ObservableMap.

Fixes dart-archive#773
Closes dart-archive#1156
rkirov pushed a commit to rkirov/angular.dart that referenced this issue Sep 30, 2014
…ifier

Lower the target time to prevent a memory overflow. Benchmark added.

To use annotate your models with @observable or use ObservableList or
ObservableMap.

Fixes dart-archive#773
Closes dart-archive#1156
@naomiblack naomiblack added this to the v1.0 milestone Oct 3, 2014
vicb added a commit that referenced this issue Oct 7, 2014
…ifier

Lower the target time to prevent a memory overflow. Benchmark added.

To use annotate your models with @observable or use ObservableList or
ObservableMap.

Fixes #773
Closes #1156
@vicb vicb closed this as completed in 85eceef Oct 7, 2014
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.