-
Notifications
You must be signed in to change notification settings - Fork 107
Adapter & Components #140
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
@david-hollifield Please try the component demo. A click on any row rendered in a viewport forces the Adapter.applyUpdates call through the controller update-method. Does this example work for you? |
@dhilt I tried that demo and nothing shows up. I'm running the latest version of Chrome so that surprised me, but it's probably just an ES6 issue. I looked at the demo source and thought it was because I was using the default $ctrl vs ctrl. I tried changing to ctrl in my component, but that made no difference unfortunately. Debugging through createValueInjector, I see that it traverses up my entire tree hierarchy to the root without finding anything to inject into. |
@dhilt After stepping through createValueInjector for the adapter attribute, I noticed that this line
never finds a scope during the entire element parent traversal. Any ideas why that would happen? |
@dhilt Ok. So if I set |
@david-hollifield Yes, we have #132 issue... And we are working on it right now! |
@david-hollifield May I ask you to look at adapter-assignments branch and to try new ui-scroll distributive in your project? Use standard Controller As syntax to bind the adapter with your component's controller. I believe it should cover your needs, and it would be very helpful if you would give a feedback! |
@dhilt I just tried the latest version with debugInfoEnabled(false) and it works great. Good job! Thanks for the quick fix. |
@david-hollifield Thanks a lot! It will be released pretty soon as 1.6.1 version. |
Like a few others, I'm having trouble getting my adapter to work. I've been successfully using an older version of ui-scroll (pre-adapter) for a long time now, but wanted to update to the latest version (1.6) to fix some jankiness in the older version. The latest version works much better and I'mreally excited to see how much it has improved. My app is mostly made up of nested angularjs 1.5+ components which, as you know, default to controllerAs: $ctrl. I've tried several iterations, but haven't been able to get the adapter to contain the methods/properties necessary to reload the list. Debugging through ui-scroll's createValueInjector() method, I see it never finds a scope to use. I've tried with $compileProvider.debugInfoEnabled(true); and $compileProvider.debugInfoEnabled(false);
Here's some things I've tried:
Nothing seems to work. I can't seem to find myAdapter in $rootScope/$scope/$ctrl. It's always just {}. What am I missing? It's pretty important for me since it's the only way now to refresh the list.
The text was updated successfully, but these errors were encountered: