getTasks
codebolt.taskplaner.getTasks(): Promise<any>
Retrieves all tasks using a WebSocket message.
Returns:
Promise<any>
A promise that resolves with the response from the get tasks event.Examples
Example
import codebolt from '@codebolt/codeboltjs';
async function exampleGetTasks() {
try {
const response = await codebolt.taskplaner.getTasks()
console.log("Tasks retrieved successfully:", response);
} catch (error) {
console.error("Failed to retrieve tasks:", error);
}
}
exampleGetTasks();
Explaination
The codebolt.taskplaner.getTasks function does not take any parameters. It retrieves the current list of tasks from the task planner.