import/Task.js
/**
     * Returns the remaining time in milliseconds. Will return `-1` if the
     * remaining time is unknown and `0` if the task is complete.
     * Note that this is an estimate that is very unreliable in the first stage,
     * thus we return `-1` if the task progress is below 10%.
     * @returns {number}
     */
Returns the remaining time in milliseconds. Will return `-1` if the
remaining time is unknown and `0` if the task is complete.
Note that this is an estimate that is very unreliable in the first stage,
thus we return `-1` if the task progress is below 10%.
@returns {number}
Returns the remaining time in milliseconds . Will return ` - 1 ` if the remaining time is unknown and ` 0 ` if the task is complete . Note that this is an estimate that is very unreliable in the first stage thus we return ` - 1 ` if the task progress is below 10% . @returns { number }
get remainingTime()
    {
        const upTime = this.upTime;
        const progress = this.progress;
        if (progress < 0.1) {
            return -1;
        }
        return (upTime * (1 / progress)) - upTime;
    }
get remainingTime ( ) { const upTime = this . upTime ; const progress = this . progress ; if ( progress < 0.1 ) { return - 1 ; } return ( upTime * ( 1 / progress ) ) - upTime ; }
Returns the remaining time in milliseconds.
Returns the remaining time in milliseconds .
// In the beginning of the task lifetime the remaining time calculation // is too unreliable. To avoid that, we return -1 if the progress is // less than 10%