You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hit npm install @uirouter/core @uirouter/sticky-states @uirouter/angularjs.
Copy ui-router-core[.min].js, ui-router-sticks-states[.min].js and ui-router-angularjs[.min].js to a directory where you can load it from, e.g. your dist directory.
I tried this solution. It somehow did not work for me. Sticky states did not work as expected. I then printed out the variable StickyStates which prints an empty object "{ }" and when I print out StickyStates.StickyStatesPlugin, it tells me that it is undefined!
npm install @uirouter/core @uirouter/sticky-states @uirouter/angularjs
.ui-router-core[.min].js
,ui-router-sticks-states[.min].js
andui-router-angularjs[.min].js
to a directory where you can load it from, e.g. your dist directory.index.html
:app.module.js
(or similar):Originally posted by @molehillrocker in #4 (comment)
I tried this solution. It somehow did not work for me. Sticky states did not work as expected. I then printed out the variable StickyStates which prints an empty object "{ }" and when I print out StickyStates.StickyStatesPlugin, it tells me that it is undefined!
Where am I making a mistake?
Here is the stub from my index.html:
` <script src="scripts/plugins/angular-ui-router/release/ui-router-core.min.js" ></script>
<script src="scripts/plugins/angular-ui-router/release/ui-router-sticky-states.js" ></script> <script src="scripts/plugins/angular-ui-router/release/ui-router-dsr.min.js" ></script> <script src="scripts/plugins/angular-ui-router/release/ui-router-angularjs.js" ></script> <script src="scripts/plugins/angular-ui-router/release/angular-ui-router.min.js" ></script> <script src="scripts/plugins/angular-ui-router/release/resolveService.min.js" ></script> <script src="scripts/plugins/angular-ui-router/release/stateEvents.min.js" ></script>`
And, here is my app.js:
.config(['$uiRouterProvider', function($uiRouterProvider) { var StickyStates = window['@uirouter/sticky-states']; console.log("StickyStates: " + JSON.stringify(StickyStates)); console.log("StickyStatesPlugin: " + JSON.stringify(StickyStates.StickyStatesPlugin)); $uiRouterProvider.plugin(StickyStatesPlugin); }]);
Please help.
The text was updated successfully, but these errors were encountered: