Code Monkey home page Code Monkey logo

angular-fitvids's Introduction

Angular FitVids

This project is an AngularJS port of FitVids from @davatron5000 and @chriscoyier. This exists to allow AngularJS users access to responsive video support through FitVids without requiring jQuery.

Browser Support

Has been loosely tests on the latest versions of Chrome and Firefox as well IE8+. Browsers must support document.querySelectorAll for it to work.

Usage

For overall usage please see FitVids. Works with AngularJS v1.2.0 and above.

<script src="/path/to/angular.min.js"></script>
<script src="path/to/angular-fitvids.js"></script>
<script type="text/javascript">
    var App = angular.module('App', ['fitVids']);
</script>

<!-- Video in your <body> -->
<div fit-vids>
    <iframe width="425" height="349" src="http://www.youtube.com/embed/FKWwdQu6_ok" frameborder="0" allowfullscreen></iframe>
</div>

Custom selector support exists like so

<div fit-vids custom-selector="iframe[src^='http://socialcam.com']">
    <iframe width="520px" height="391px" src="http://socialcam.com/videos/XRMP3Y5t/embed?utm_campaign=web&utm_source=embed" frameborder="0" allowfullscreen></iframe>
</div>

angular-fitvids's People

Contributors

adamfairholm avatar cbumgard avatar chriscoyier avatar davatron5000 avatar elliotttf avatar emiluzelac avatar flynfish avatar jacobbennett avatar jimmyhillis avatar krinkle avatar lerouxb avatar mohnish avatar quayzar avatar sstarr avatar

Watchers

 avatar  avatar

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.