Tuesday, October 6, 2015

How to Optimize Landing Pages to Boost Social Media Conversions

ll-optimize-landing-page-conversions-560

Do you want more conversions from your social traffic? Are you using landing pages? Directing targeted social media traffic to relevant landing pages helps you convert visitors into leads. In this article you’ll discover how to optimize landing pages to boost social media conversions. Why Landing Pages Rather than direct social media traffic to your home […]

This post How to Optimize Landing Pages to Boost Social Media Conversions first appeared on Social Media Examiner.
Social Media Examiner - Your Guide to the Social Media Jungle


by Lesya Liu via Social Media Examiner

Peanutize Me!

Peanutize Me! is a hyper-shareable experience that allows any user to create themselves as a Peanuts character. The site has hundreds of custom assets, allowing for millions of combos. Over 1,000,000 shares in 24hrs
by via Awwwards - Sites of the day

Stretchy : JavaScript Form Element Autosizing

Stretchy is a javascript library to make form elements autosizing, the way it should be.

Features:

  • Handles multiple types of form controls
  • Tiny footprint
  • Automatically accounts for newly added controls
  • Restrict form controls by a selector
  • Completely standalone
  • Plays well with existing HTML/CSS
  • Works in all modern browsers

The post Stretchy : JavaScript Form Element Autosizing appeared first on jQuery Rain.


by Admin via jQuery Rain

OSG.JS : Javascript Implementation of OpenSceneGraph

OSGJS is a WebGL framework based on OpenSceneGraph concepts. It allows an individual to use an “OpenSceneGraph-like” toolbox to interact with WebGL via JavaScript, and provides facilities for exporting various assets to the osgjs format. The API is kept as similar to OpenSceneGraph as possible, providing a familiar environment to veterans of the library and introducing newcomers to a popular and heavily-scrutinzed set of interfaces.

The post OSG.JS : Javascript Implementation of OpenSceneGraph appeared first on jQuery Rain.


by Admin via jQuery Rain

Clipboard.js : Copy to Clipboard without Flash

Copying text to the clipboard shouldn’t be hard. It shouldn’t require dozens of steps to configure or hundreds of KBs to load. But most of all, it shouldn’t depend on Flash or any bloated framework.

The post Clipboard.js : Copy to Clipboard without Flash appeared first on jQuery Rain.


by Admin via jQuery Rain

Monday, October 5, 2015

Be #SEO Smart in 2015 – #infographic

Be #SEO Smart in 2015 – #infographic

"How strong is your search engine ranking? If your site isn’t mobile-friendly, fast-loading, and clutter-free, it might be weaker than you think. Check out this infographic for tips on how to keep your site optimized in 2015."

by Irfan Ahmad via Digital Information World

Asynchronous APIs Using the Fetch API and ES6 Generators

ECMAScript 6 (a.k.a. ECMAScript 2015 or ES6) brings a number of new features to JavaScript which will make the language a good fit for large applications. One of these features is better support for asynchronous programming using promises and generators. Another is the addition of the Fetch API which aims to replace XMLHttpRequest as the foundation of communication with remote resources.

The Fetch API’s methods return ES6 Promise objects, which can be used in conjunction with generators to form the basis of complex asynchronous operations. This could be anything from a chain of asynchronous operations, where each operation depends on the value returned by the previous one, to an asynchronous call that has to be made repeatedly to a server to get the latest update.

In this article we will see how the Fetch API can be used in conjunction with generators to build asynchronous APIs. The Fetch API is currently supported in Chrome, Opera, Firefox and Android browsers. We have a polyfill available from GitHub for unsupported browsers.

As ever, the code for this article can be found on our GitHub repository and there is a demo of the final technique at the bottom of the article.

Generators for Asynchronous Operations

[author_more]

Tip: If you need a refresher on what generators are and how they work, check out: ECMAScript 2015: Generators and Iterators

So how can we use generators to perform async operations? Well, if we analyze the way generators work we will find the answer.

A generator function implementing an iterator has the following structure:

function *myIterator(){
  while(condition){
    //calculate next value to return
    yield value;
  }
}

The yield keyword is responsible for returning a result and halting execution of the iterator function until it is next invoked. It also keeps the state of the function instead of rerunning everything when next you call it, effectively remembering the last place it left off.

We can re-imagine the above function without while loop as follows:

function *myIterator(){
  //calculate value 1
  yield value1;

  //calculate value 2
  yield value2;
  ...

  //calculate value n
  yield valuen;
}

The behavior of the function will be identical in both of the above cases. The only reason for using the yield keyword is to pause the execution of the function until the next iteration (which in itself seems kind of asynchronous). And as the yield statement can return any value, we can also return Promises and make the function run multiple asynchronous calls.

Using Generators with the Fetch API

Tip: For a refresher on the Fetch API, check out: Introduction to the Fetch API

As mentioned earlier the Fetch API is intended to replace XMLHttpRequest. This new API provides control over every part of an HTTP request and returns a Promise that either resolves or rejects based on the response from the server.

Long Polling

One of the use cases where the Fetch API and generators can be used together is long polling. Long polling is a technique in which a client keeps sending requests to a server until it gets a response. Generators can be used in such a case to keep yielding the responses unless the response contains data.

Continue reading %Asynchronous APIs Using the Fetch API and ES6 Generators%


by Ravi via SitePoint