⚡ Project management that doesn't become the project. Boards, Gantt charts, and GitHub integration. Self-host it or use Kaneo Cloud.
TypeScript honoissue-managementissue-trackerjira-alternativekanbanlinear-alternativemcpproject-managementreactself-hostedtypescript
import type { ProjectWithTasks } from "@/types/project";
import type Task from "@/types/task";
export function scopeTasks(
project: ProjectWithTasks | null | undefined,
scope: "board" | "backlog" | "schedule",
): Task[] {
if (!project) return [];
const boardTasks = project.columns.flatMap((column) => column.tasks);
if (scope === "board") return boardTasks;
if (scope === "backlog") {
return [...(project.plannedTasks ?? []), ...(project.archivedTasks ?? [])];
}
return [...boardTasks, ...(project.plannedTasks ?? [])];
}