Skip to content

ui-view inside a directive that does NOT ng-transclude does not work #2033

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

Closed
angel1st opened this issue Jun 12, 2015 · 5 comments
Closed

ui-view inside a directive that does NOT ng-transclude does not work #2033

angel1st opened this issue Jun 12, 2015 · 5 comments

Comments

@angel1st
Copy link

Hi there,
I am using ui-router (v.0.2.14) and have ui-view nested inside angular-pageslide-directive - https://github.com/dpiccone/ng-pageslide. As you can see from the directive's code - it does NOT transclude (transclude: false).
I am experienced the same issue described here - #774 - as long as I put ui-vew inside the directive, the ui-view becomes empty.
Here is the sample code:

<div class="row">
    <div class="col-lg-3">
        <div ui-view="contacts" class="row"></div>
    </div>
    <div class="col-lg-6">
        <div ui-view="calls" class="row"></div>
    </div>

    <pageslide ps-open="chatOpened">
        <div ui-view="messaging"></div>
    </pageslide>
</div>

here it the ui-views definitions:

"calls@room": {
    templateUrl: 'partials/room-calls.html',
    controller: 'CallsCtrl'
},
"contacts@room": {
    templateUrl: "partials/room-contacts.html",
    controller: 'ContactsCtrl'
},
"messaging@room": {
    templateUrl: "partials/room-messaging.html",
    controller: 'MessagingCtrl'
}

any help would be appreciated...
Best Regards,
Angel

@GerritJanMollenhorst
Copy link

Hi
I am facing exactly the same problem with v0.2.15. Any progress made?
Please share your current status on the matter.

Regards,
Gerrit-Jan

@leandro-shifteight
Copy link

Same here, using ui-view inside a directive is not working.

@jvmccarthy
Copy link

I'm also running into trouble getting ui-view to work inside a directive. I stumbled onto something odd, though. If I use ui-view as an attribute, like <div ui-view></div>, it doesn't work in a directive. However, used as an element, like <ui-view></ui-view>, it works. Can anyone confirm this? Any reason why the ui-view directive would work as a element and not an attribute?

@eddiemonge
Copy link
Contributor

@jvmccarthy can you open a new issue with that and a plnkr showing it in action?

Has anyone tried this with the new feature-1.0 branch?
https://gist.github.com/christopherthielen/b3fc0304b737a4bf8ec9

@eddiemonge
Copy link
Contributor

Closing due to inactivity

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

No branches or pull requests

5 participants