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

nested ng-transcludes with isolate scopes broken #6435

Closed

Description

@reinerp

See http://jsfiddle.net/c7UvM/10/. I have two directives, <outer> and <inner>, each of which uses isolate scopes and ng-transclude. The template for <outer> contains <inner><div ng-transclude></div></inner>. This nested use of ng-transclude causes the scope to be wired up wrongly.

What's my use case? Currently, my <inner> directive is responsible for creating a stylized link, and my <outer> directive uses that stylized link to show a specific piece of text. These are completely separate responsibilities, so I'd like to keep them separate.

Activity

  1. julien-gm commented on Feb 25, 2014

    @julien-gm

    I think I have a similar issue...
    Here is the fiddle http://jsfiddle.net/a47Rz/2/
    You can see that if you remove the ng-if, it's working fine. The error seems to occur on the $transclude of the ngIfDirective...

    Thanks for you help.

  2. sheab commented on Mar 20, 2014

    @sheab

    I'm having the same issue

  3. Xesued commented on Apr 4, 2014

    @Xesued

    +1

  4. petebacondarwin commented on May 15, 2014

    @petebacondarwin
    Contributor

    Possibly fixed by #7387

  5. odebreu commented on May 28, 2014

    @odebreu

    I tried to make a similar example work with the angularjs 1.3.0-beta.10 (which should include the fix #7387) but it seems that the issue is still there.
    Here is the example: http://plnkr.co/edit/0hFFHknDps2krtK1D9ud?p=preview

  6. added this to the milestone on Jun 21, 2014
  7. rodyhaddad commented on Jun 26, 2014

    @rodyhaddad
    Contributor

    Updating to 1.3.0-beta.13 makes all 3 jsfiddles/plunkr work as expected (1, 2, 3)

    Closing this as it seems fixed. Let me know if I missed anything to re-open it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions