Git Product home page Git Product logo

Comments (5)

oliodj avatar oliodj commented on August 22, 2024

could line 146 be optional?

var duration = $state.previous.name === '' ? 0 : from.duration, // don't trigger transition on boot

from angular-gsapify-router.

homerjam avatar homerjam commented on August 22, 2024

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.

oliodj avatar oliodj commented on August 22, 2024

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.

homerjam avatar homerjam commented on August 22, 2024

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.

oliodj avatar oliodj commented on August 22, 2024

Ah ok, great have sent a PR

from angular-gsapify-router.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.