Conversation
Add ncyStateParams to viewScope
Generate dist and release with ncyStateParams
|
Changes Unknown when pulling f28ce22 on davinci-studio:master into * on ncuillery:master*. |
There was a problem hiding this comment.
Hi, many thanks for the PR.
I don't understand why you attach the stateParams to the viewScope here : it is the same scope of the one handled by the view controller (where you can already inject $stateParams and use it).
It make more sense if you attach the stateParams to the scope of the directive (scope) in order to use it in custom templates. Maybe, is that you wanted to do ?
There was a problem hiding this comment.
I forget an important part:
Before doing anything in your branch history, please can you revert changes on release/angular-breadcrumb.js and release/angular-breadcrumb.min.js ?
I change these file only when I made a new release (it allows users to always have a stable version when they checkout the master).
There was a problem hiding this comment.
Hi,
I use translations in the breadcrumb label, eg. label: {{ 'breadcrumb.login.admin' | translate }} by changing the last part of my translation key from stateParams (admin/company/user). I had some troubles when I tried to inject the stateParams from controller scope and I was getting undefined in some cases.
Revert changes from release directory? If you would like to add this changes to the official repository, of course.
Usage:
url: '/login/:userType',
ncyBreadcrumb: {
label: "{{ ncyStateParams.userType }}"
}