title: How to pass an arg to the function inside lodash's once function?
body: <p>So I am calling a function that calls lodash's once function:</p>
  
  <pre><code>  if (isPageTwo) {
      sendSegmentData(sendEnhancedTrackEvent);
    }
  </code></pre>
  
  <p>And I have the functions defined here:</p>
  
  <pre><code>const pageTwoSegmentEvent = (sendEnhancedTrackEvent) =&gt; {
    const enhanceableData = {
      name: 'Page loaded',
      properties: {
        ...defaultProps,
        cid: getCid(),
        epid: getEpid(),
        name: 'ReviewExperienceModernDoubleStep'
      }
    };
    sendEnhancedTrackEvent(enhanceableData);
  }
  const sendSegmentData = (sendEnhancedTrackEvent) =&gt; {
    once(() =&gt; {
      pageTwoSegmentEvent(sendEnhancedTrackEvent);
    });
  }
  </code></pre>
  
  <p>I am trying to pass the sendEnhancedTrackEvent callback function to the pageTwoSegmentEvent function but I guess the way I'm trying to pass it through the once function pageTwoSegmentEvent never gets called.  Does anyone know how to do this?</p>