You're viewing docs for v5.15.4, an older version of Font Awesome.

Discover and prevent conflict issues when loading Font Awesome in an environment that might be loading other versions of Font Awesome as well.


Before You Get Started

This API is for developers writing code that uses the Conflict Detection API. Everyone else can use Conflict Detection.

The conflict detector uses the global object window.FontAwesomeDetection as an interface for you to configure settings, override functionality, or query results from your code.

Access it by including a <script> tag in your page, before the <script> that loads conflict-detection.js. Assign an object to window.FontAwesomeDetection that has your configs and overrides. Like this:

    <!-- bunch of stuff -->
      <!-- more stuff -->
      <script data-fa-detection-ignore type="text/javascript">
        window.FontAwesomeDetection = {
          timeout: 1000,
          report: function(params){
            // Do your own reporting here


In this example, we set the timeout value, and we also override the report() method. So the conflict detector will wait only 1000 milliseconds instead of the default 2000 for each test before concluding whether it presents a conflict. And when it's ready to report, it will call this report() instead of the built-in report implementation.