Giter Club home page Giter Club logo

angular-wait's People

Contributors

michikono avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

Forkers

goupviet hpix

angular-wait's Issues

Animating the transitions between wait-loading and wait-done?

I'm going to play around with this a little, but do you have any quick guidance on how I could leverage angular animations to smoothly transition between the two states provided by this directive?

I'm thinking just something as simple as fade out the loading content and immediately fade in the done content. I'm new to angular animations so thanks in advance for any help if you've considered this already.

API Design

Trying to get my head around the different use cases folks have for deferred directive loading from this ticket.

At first read, I thought most folks were looking to delay the execution of a post-link function and controller associated with a directive until after some dependencies had resolved. I noticed angular-wait's slugline implies a focus on load state:

Angular directive for showing pending ("loading...") content

Another good use case.

I see it's transcluding content. When someone puts a directive inside <wait-done>, do you know which steps would be executed BEFORE the wait resolves? compile? controller? pre-link? post-link? I think it would do the compile but nothing else, right?

If all you need is deferred directive evaluation, a syntax that emphases the optional-ness and composability of the feature might be preferable:

<user-profile-form waits="user"></user-profile-form>

If the focus is on indicating load state, a syntax that emphasizes the either/or-ness of the situation may be better, like what you have now.

Anyway, sort of thinking out loud, but also trying to figure out how many of the steps in the compile process are possible to defer.

Support for nesting wait directives?

Do you know off hand if it's possible to nest wait directives inside each other? Something like

<wait until-not-null="relativelyQuickProperty">
  <wait-loading>...</wait-loading>
  <wait-done>
    ...a bunch of content...
    <wait until-not-null="someDelayedValue">
      ...
    </wait>
  </wait-done>
</wait>

I'm hoping to use this to show a status page, but one where the critical values load and show relatively quickly, and some supporting graphs are shown once their data is fetched (which takes longer).

Some initial testing shows that the inner wait seems to cause them all to wait, but I'm a little over me head on how these nested directives would interact.

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.