GithubHelp home page GithubHelp logo

fb_intercept_polyfill's Introduction

fb_intercept_polyfill

A polyfill for using fb_intercept across hhvm 3.24 -> 4.present

Why you don't need this polyfill. The polyfill bridges the gap between a hhvm that understands inout without being in the transition period for &$references and one that doesn't understand &$references. The HH\Lib\Ref<T> is a class does not require runtime support, so it can be used as a mediator. If your hhvm is not in the transition period for &$references, but it does have HH\Lib\Ref<T> support, you may want to use this polyfill.

Limitations

fb_intercept() is a built-in function. This gives it the superpower that it can't be intercepted itself. The polyfill is userland code, so it can be intercepted. Therefore you can't use the catchall interceptor key '' (empty string), since you would be intercepting calls to the polyfill itself. This makes it impossible to call fb_intercept() after that. The polyfill will throw if you pass it the catchall key, telling you that this is not supported. If you intercept the polyfill by name intentionally, you'll not be able to restore it. So don't do that. ๐Ÿ˜‰

Installation instructions for library authors

Version v1.x.x and v2.x.x will retain API intercompatibility as a promise. v1 will only run on hhvm 4.28 and below and v2 will only run on 4.20 and up. The public API has not changed, only the hhvm version requirement and some implementation details.

We therefore STRONGLY advice that your version constraint for this library is "^1|^2". This is required to be installable on all hhvm versions.

Users of this library who do not intend to run on older hhvm versions can set a "^2" constraint, but the "^1|^2" constraint would also work for you.

fb_intercept_polyfill's People

Contributors

lexidor avatar tyronjung-quizlet avatar

Watchers

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

fb_intercept_polyfill's Issues

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.