Giter VIP home page Giter VIP logo

adapter's Introduction

Build Status

WebRTC adapter

[adapter.js] is a shim to insulate apps from spec changes and prefix differences. In fact, the standards and protocols used for WebRTC implementations are highly stable, and there are only a few prefixed names. For full interop information, see webrtc.org/web-apis/interop.

Install

Bower

bower install webrtc-adapter#gh-pages

One caveat is that the version is gh-pages hence you will get the latest adapter.js unless you manually specify a version. See Usage instructions for more details.

NPM

npm install webrtc-adapter

Usage

NPM

Copy to desired location in your src tree or use a minify/vulcanize tool (node_modules is usually not published with the code). See webrtc/samples repo as an example on how you can do this.

Prebuilt releases

Web

In the gh-pages branch prebuilt ready to use files can be downloaded/linked directly. Latest version can be found at http://webrtc.github.io/adapter/adapter-latest.js. Specific versions can be found at http://webrtc.github.io/adapter/adapter-N.N.N.js, e.g. http://webrtc.github.io/adapter/adapter-1.0.2.js.

Bower

You will find adapter.js in bower_components/webrtc-adapter/.

Due to using the gh-pages branch as a version, you cannot use the bower package version for making sure you are using the correct version, rather you have to statically link the adapter-version file yourself, e.g. if you want version 1.0.5 you have to use the following file: bower_components/webrtc-adapter/adapter-1.0.5.js.

NPM

In node_modules/webrtc-adapter/out/ folder you will find 4 files:

  • adapter.js - includes all the shims and is visible in the browser under the global adapter object (window.adapter).
  • adapter_no_edge.js - same as above but does not include the Microsoft Edge (ORTC) shim.
  • adapter_no_edge_no_global.js - same as above but is not exposed/visible in the browser (you cannot call/interact with the shims in the browser).
  • adapter_no_global.js - same as adapter.js but is not exposed/visible in the browser (you cannot call/interact with the shims in the browser).

Include the file that suits your need in your project.

Development

Detailed information on developing in the webrtc github repo can be found in the WebRTC GitHub repo developer's guide.

Head over to test/README.md and get started developing.

Publish a new version

  • Go the the adapter repository root directory
  • Make sure your repository is clean, i.e. no untracked files etc
  • Depending on the impact of the release, either use patch, minor or major in place of <version>. Run npm version <version> -m 'bump to %s' and type in your password lots of times (setting up credential caching is probably a good idea).
  • Create and merge the PR if green in the GitHub web ui
  • Run git pull
  • Run npm publish
  • Done! There should now be a new release published to NPM and the gh-pages branch.

Note: Currently only tested on Linux, not sure about Mac but will definitely not work on Windows.

adapter's People

Contributors

agouaillard avatar alvestrand avatar andresusanopinto avatar anthmfs avatar byronclark avatar calebboyd avatar chuckhays avatar cvan avatar cwilso avatar doep avatar felixmcfelix avatar fippo avatar fischman avatar gasp avatar jan-ivar avatar jiayliu avatar jnoring-hv avatar juandebravo avatar juberti avatar kaptenjansson avatar laurent-le-graverend avatar macest avatar marwahvikas avatar minyuel avatar piranna avatar sachanacar avatar samdutton avatar tkchin avatar wpp avatar yellowdoge 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.