开发者

how does this General Assembly website fade in?

开发者 https://www.devze.com 2023-03-06 07:27 出处:网络
it look开发者_Go百科s like http://www.generalassemb.ly/ has set the container to 0 opacity, i\'m just curious if it\'s faded in by javascript or css3. seems like a great way to load a complete page. a

it look开发者_Go百科s like http://www.generalassemb.ly/ has set the container to 0 opacity, i'm just curious if it's faded in by javascript or css3. seems like a great way to load a complete page.


as you can see in app.js it's animating using jquery.

$(window).load(function() {
 $('#container').show();   

 $('#loading').animate({
    opacity: 0
   }, 200, function () {
    $('#loading').hide();
   });

 $("#container").animate({
    opacity: 1
   }, 1000);
 });


Javascript, using Jquery. Although it's possible to make these sort of transitions with CSS3 take a look here.


Just a suggestion: take a look at the view-->source of the page. It is, imo, extraordinarily clean markup. You'll be able to follow everything very easily. An hour spent studying the source will be very helpful and instructivefor you and will give you some great insights. So much so that you'll never again have to ask a question like yours. You'll be answering such questions instead :-)

0

精彩评论

暂无评论...
验证码 换一张
取 消