Home / Function/ progress() — fastapi Function Reference

progress() — fastapi Function Reference

Architecture documentation for the progress() function in termynal.js from the fastapi codebase.

Function javascript FastAPI Applications calls 1 called by 1

Entity Profile

Dependency Diagram

graph TD
  c1666950_ab84_7e24_2a36_b1d1a8751b9d["progress()"]
  000471a9_ef7a_d9dc_ef48_af16a8d6655c["Termynal"]
  c1666950_ab84_7e24_2a36_b1d1a8751b9d -->|defined in| 000471a9_ef7a_d9dc_ef48_af16a8d6655c
  f693669c_751b_13db_a04c_e34d87d400df["start()"]
  f693669c_751b_13db_a04c_e34d87d400df -->|calls| c1666950_ab84_7e24_2a36_b1d1a8751b9d
  b0dad3b4_7046_f9b4_bbde_3ae1dee7acce["_wait()"]
  c1666950_ab84_7e24_2a36_b1d1a8751b9d -->|calls| b0dad3b4_7046_f9b4_bbde_3ae1dee7acce
  style c1666950_ab84_7e24_2a36_b1d1a8751b9d fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

docs/en/docs/js/termynal.js lines 187–206

    async progress(line) {
        const progressLength = line.getAttribute(`${this.pfx}-progressLength`)
            || this.progressLength;
        const progressChar = line.getAttribute(`${this.pfx}-progressChar`)
            || this.progressChar;
        const chars = progressChar.repeat(progressLength);
		const progressPercent = line.getAttribute(`${this.pfx}-progressPercent`)
			|| this.progressPercent;
        line.textContent = '';
        this.container.appendChild(line);

        for (let i = 1; i < chars.length + 1; i++) {
            await this._wait(this.typeDelay);
            const percent = Math.round(i / chars.length * 100);
            line.textContent = `${chars.slice(0, i)} ${percent}%`;
			if (percent>progressPercent) {
				break;
			}
        }
    }

Domain

Subdomains

Calls

Called By

Frequently Asked Questions

What does progress() do?
progress() is a function in the fastapi codebase, defined in docs/en/docs/js/termynal.js.
Where is progress() defined?
progress() is defined in docs/en/docs/js/termynal.js at line 187.
What does progress() call?
progress() calls 1 function(s): _wait.
What calls progress()?
progress() is called by 1 function(s): start.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free