# Method: handsfree.pause()


Pauses the main loop while keeping the webcam stream active. By keeping the stream open, pausing allows you to instantly unpause without needing to wait for a new stream to be created.

In complex apps with multiple routes, loading screens, or processing heavy workflows the handsfree.pause() method helps you free resources until tracking is needed again.

Pausing can also be used in combination with start as a sort of "preloader" to load all dependencies for all models, making switching between models instant.

This is different from handsfree.stop(), which ends the webcam stream completely.

# Example

const handsfree = new Handsfree({weboji: true})

// Load dependencies and start the webcam, but don't start the loop
handsfree.start(() => {

# See also

Last Updated: 12/17/2020, 1:15:12 PM