TaskSignal: priority property
Prioritized Task Scheduling API
Prioritized Task Scheduling API
The read-only **`priority`** property of the TaskSignal interface indicates the signal [priority](/docs/Web/API/Prioritized_Task_Scheduling_API#task_priorities).
The initial value is set in the associated TaskController by specifying it as an argument to the [`TaskController` constructor](/docs/Web/API/TaskController/TaskController) (by default it is `"user-visible"`).
The priority of the signal can be changed by calling TaskController.setPriority() on the associated controller.
For [tasks with a mutable priority](/docs/Web/API/Prioritized_Task_Scheduling_API#mutable_and_immutable_task_priority), this value is used to set the initial task priority and later to change it.
Tasks with an immutable priority will ignore the value.
## Value
A string indicating the signal [priority](/docs/Web/API/Prioritized_Task_Scheduling_API#task_priorities).
This will be one of: `"user-blocking"`, `"user-visible"`, `"background"`.
## Examples
The `priority` is most commonly used by developers to determine the new priority following [`prioritychange`](/docs/Web/API/TaskSignal/prioritychange_event) events.
See [TaskSignal: prioritychange event](/docs/Web/API/TaskSignal/prioritychange_event#examples) for a live example.
## Specifications
## Browser compatibility
Cite this
"TaskSignal: priority property". MDN Web Docs. CC BY-SA 2.5 (MDN). https://developer.mozilla.org/en-US/docs/Web/API/TaskSignal/priority JSON record · API collection · BibTeX · RIS · CSL-JSON · citation policy