Giter Site home page Giter Site logo

leapmotion's People

Contributors

karolikl avatar sindresorhus avatar

Stargazers

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

Watchers

 avatar  avatar  avatar  avatar

leapmotion's Issues

XHR over file protocol

I saw that XHR wasn't running over the file protocol which seemed like a nice challenge. So, I just pushed a small patch XDomain to solve this:

Save this file and run it:

<!DOCTYPE HTML>
<html>
<body>

  <h3>XDomain Demo</h3>
  <h5>From '<span id="host"></span>'</h5>
  <h5>To 'http://s3.amazonaws.com/jpillora-usa/data1.json'</h5>

  <script src="http://s3.amazonaws.com/jpillora-usa/xdomain/0.5.min.js"
          slave="http://s3.amazonaws.com/jpillora-usa/xdomain/proxy.html"></script>

  <script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.js"></script>

  <pre id='output'></pre>

  <script type="text/javascript">
    //show current origin
    $("#host").html(xdomain.origin);
    //jquery ajax call
    $("#output").load('http://s3.amazonaws.com/jpillora-usa/xdomain/data1.json');
  </script>

</body>
</html>

Or paste this in your address bar. It also works as data-uri, which is pretty neat.

data:text/html;base64,PCFET0NUWVBFIEhUTUw+CjxodG1sPgo8Ym9keT4KCiAgPGgzPlhEb21haW4gRGVtbzwvaDM+CiAgPGg1PkZyb20gJzxzcGFuIGlkPSJob3N0Ij48L3NwYW4+JzwvaDU+CiAgPGg1PlRvICdodHRwOi8vczMuYW1hem9uYXdzLmNvbS9qcGlsbG9yYS11c2EvZGF0YTEuanNvbic8L2g1PgoKICA8c2NyaXB0IHNyYz0iaHR0cDovL3MzLmFtYXpvbmF3cy5jb20vanBpbGxvcmEtdXNhL3hkb21haW4vMC41Lm1pbi5qcyIKICAgICAgICAgIHNsYXZlPSJodHRwOi8vczMuYW1hem9uYXdzLmNvbS9qcGlsbG9yYS11c2EveGRvbWFpbi9wcm94eS5odG1sIj48L3NjcmlwdD4KICAgCiAgPHNjcmlwdCBzcmM9Imh0dHA6Ly9hamF4Lmdvb2dsZWFwaXMuY29tL2FqYXgvbGlicy9qcXVlcnkvMS9qcXVlcnkuanMiPjwvc2NyaXB0PgoKICA8cHJlIGlkPSdvdXRwdXQnPjwvcHJlPgoKICA8c2NyaXB0IHR5cGU9InRleHQvamF2YXNjcmlwdCI+CiAgICAvL3Nob3cgY3VycmVudCBvcmlnaW4KICAgICQoIiNob3N0IikuaHRtbCh4ZG9tYWluLm9yaWdpbik7CiAgICAvL2pxdWVyeSBhamF4IGNhbGwKICAgICQoIiNvdXRwdXQiKS5sb2FkKCdodHRwOi8vczMuYW1hem9uYXdzLmNvbS9qcGlsbG9yYS11c2EveGRvbWFpbi9kYXRhMS5qc29uJyk7CiAgPC9zY3JpcHQ+Cgo8L2JvZHk+CjwvaHRtbD4K

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.