Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Limit ng-repeat boundary (ng-repeat Extension) #2364

Closed
hsdk123 opened this issue Apr 11, 2013 · 2 comments
Closed

Limit ng-repeat boundary (ng-repeat Extension) #2364

hsdk123 opened this issue Apr 11, 2013 · 2 comments

Comments

@hsdk123
Copy link

hsdk123 commented Apr 11, 2013

ng-repeat currently works in the following:
[span ng-repeat="value in values"]
{{$index}}
[/span]

where the specific element that has the ng-repeat is repeated.
The problem arises though when we want to repeat not just one specific element, but multiple. For example, if I wanted to repeat the following:

[span] {{$index}} [/span]
[div] {{$index}} [div]

I'd have to create some sort of container specifically for the ng-repeat. The thing is, the container itself will also get repeated. I feel this container making is redundant and adds unnecessary layers to the html.

It'd be nice if we could have an extension to the current ng-repeat along these lines:

[div ng-repeat-inner="square in squares"]

[span] {{square.index}} [/span]
[a] asd [/a]

[/div]

JSFiddle here: http://jsfiddle.net/fZz3W/12/

Where the "ng-repeat-inner" would only repeat the descendants within itself, not including. This would save us from having to make superfluous containers purely for repetition.

@jmou
Copy link

jmou commented Apr 23, 2013

This looks like the same issue #1891

@btford btford closed this as completed Aug 24, 2013
@btford
Copy link
Contributor

btford commented Aug 24, 2013

As part of our effort to clean out old issues, this issue is being automatically closed since it has been inactivite for over two months.

Please try the newest versions of Angular (1.0.8 and 1.2.0-rc.1), and if the issue persists, comment below so we can discuss it.

Thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants