title: Avoid deploy a function to production
body: <p>Assume I use the next simple function for logging</p>
  <pre class="lang-js prettyprint-override"><code>import * as functions from 'firebase-functions';
  
  export const logOnWrite = functions.firestore
    .document('{collection}/{document}')
    .onWrite((_, context) =&gt; {
      functions.logger.log('onWrite', context);
    });
  </code></pre>
  <p>What is the best way to deploy a specific functions only if I use <code>firebase emulators</code> ?</p>
  <p>I know that I can enable/disable Background Function Triggers but this is not the same.</p>