Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript Can I put a timeout function inside a for loop?

  • This topic is empty.
Viewing 15 posts - 16 through 30 (of 46 total)
  • Author
    Posts
  • #175873
    JacobPeters
    Participant

    This might remove your need for jQuery too.

    #175876
    nixnerd
    Participant

    True dat homie :)

    #175878
    JacobPeters
    Participant

    Looks like it should work.

    http://codepen.io/jacobcpeters/pen/vxItB

    #175879
    nixnerd
    Participant

    I know. I made one that works too… but locally the photo just disappears. What gives?

    #175880
    JacobPeters
    Participant

    Can I see the code that doesn’t work?

    #175882
    nixnerd
    Participant

    I’m trying to post it. I keep getting blocked by the firewall?

    #175883
    nixnerd
    Participant
    <svg>
        <filter id="blur">
            <feGaussianBlur stdDeviation="5" />
        </filter>
    </svg>
    
    <div>
        <div></div>
        <div></div>
    </div>
    
    #175884
    nixnerd
    Participant

    I have no idea why I can’t post that code.

    #175886
    JacobPeters
    Participant

    What’s the CSS that goes with it?

    #175887
    nixnerd
    Participant

    I figured it out. Bunk file path. The CSS is getting me blocked too. You can’t just do:

    filter: url(“#blur”);

    Gotta be absolute. Didn’t think of that.

    #175888
    nixnerd
    Participant

    Every freaking file path to #blur is failing. It only works when I do an in-line style.

    #175889
    nixnerd
    Participant

    Got it!

    filter: you are el ( ” dot dot/dot dot/#blur”);

    #175890
    nixnerd
    Participant

    But now the slider is slower than ever. Back to square one. I don’t think switching to translate will make up for the bottleneck that is TONS of svg filters.

    #175891
    nixnerd
    Participant

    The REAL issue… is the fact that I need a function that can create other functions while it iterates over an array.

    Does anyone know how that can be done?

    #175892
    JacobPeters
    Participant

    Can you put it on just the main .backstrip div? That might help.

Viewing 15 posts - 16 through 30 (of 46 total)
  • The forum ‘JavaScript’ is closed to new topics and replies.