Comments (5)
could line 146 be optional?
var duration = $state.previous.name === '' ? 0 : from.duration, // don't trigger transition on boot
from angular-gsapify-router.
What are you actually trying to do? Animate a state in at the beginning?
If so then the simplest thing to do is probably just trigger the state by forcing the transition with $state.go('stateName', {reload: true})
or switching to a blank intermediary state and then immediately switching back.
from angular-gsapify-router.
exactly. have been figuring out workarounds to trigger a transition on boot on every site I've used this on, feels a bit hacky though. would making transition on boot configurable cause any issues? if not I don't mind making a pull request...
from angular-gsapify-router.
Well it would be a pretty major change - the reason its setup this way is to mirror the behaviour of ui-router
which doesn't cause a transition on initial load, I've taken this to be the expected behaviour now.
The obvious place for this option would be the provider, you'd then set it in the config stage of the app:
gsapifyRouterProvider.initialTransitionEnabled = true; // false by default
Would definitely take a PR for that...
from angular-gsapify-router.
Ah ok, great have sent a PR
from angular-gsapify-router.
Related Issues (20)
- Set animation with state.go HOT 2
- Angular 1.3.7 HOT 1
- Laggy Performance on iOS HOT 3
- Modal hidden HOT 3
- Page (state?) moves down when clicking HOT 6
- What's the src file? HOT 2
- Issues with transitions and ui-view HOT 1
- transition on first load of state, no previous state HOT 8
- Where can I see a list of the animation names that this comes with? HOT 12
- TweenMax not defined HOT 1
- Could not resolve '' from state 'gsapifyRouterBlankState' HOT 8
- Using resolve inside the router gives gsapifyRouterBlankState error HOT 1
- Slider previous and next HOT 2
- Not working with angular material HOT 3
- State not re-resolved properly by forced initial transition
- Missing content on page after transition HOT 3
- Leave blocks and priority not honored with ui-router 1.0 HOT 3
- Angular Type Checking not the same as previous logic HOT 2
- Get Error: undefined is not an object (evaluating 'state.data') HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from angular-gsapify-router.