diff --git a/src/tasks/handlers.ts b/src/tasks/handlers.ts
index fd93790..baff7a7 100644
--- a/src/tasks/handlers.ts
+++ b/src/tasks/handlers.ts
@@ -4,6 +4,4 @@ import { Default as TaskListDefault } from "./task-list.story";
export const taskListHandler = http.get("/tasks", () => HttpResponse.json(TaskListDefault.args));
export const taskListErrorHandler = http.get("/tasks", () => HttpResponse.json([]));
-export const handlers = [
- taskListHandler,
-]
+export const handlers = [taskListHandler];
diff --git a/src/tasks/task.story.tsx b/src/tasks/task.story.tsx
index 444e083..7e35651 100644
--- a/src/tasks/task.story.tsx
+++ b/src/tasks/task.story.tsx
@@ -1,4 +1,4 @@
-import { Task } from "./task";
+import { Task, type TaskProps } from "./task";
export default {
component: Task,
@@ -12,7 +12,7 @@ export default {
};
export const Default = {
- render: (args) => (
+ render: (args: TaskProps) => (
@@ -27,7 +27,7 @@ export const Default = {
};
export const Pinned = {
- render: (args) => (
+ render: (args: TaskProps) => (
@@ -42,7 +42,7 @@ export const Pinned = {
};
export const Archived = {
- render: (args) => (
+ render: (args: TaskProps) => (
@@ -59,7 +59,7 @@ export const Archived = {
const longTitleString = `This task's name is absurdly large. In fact, I think if I keep going I might end up with content overflow. What will happen? The star that represents a pinned task could have text overlapping. The text could cut-off abruptly when it reaches the star. I hope not!`;
export const LongTitle = {
- render: (args) => (
+ render: (args: TaskProps) => (
diff --git a/src/tasks/use-tasks.ts b/src/tasks/use-tasks.ts
index 3d4383f..51db350 100644
--- a/src/tasks/use-tasks.ts
+++ b/src/tasks/use-tasks.ts
@@ -2,7 +2,7 @@
import * as React from "react";
-export interface Task {
+interface Task {
id: string;
title: string;
state: "TASK_INBOX" | "TASK_PINNED" | "TASK_ARCHIVED";
diff --git a/tsconfig.json b/tsconfig.json
index 4714bd9..57b3588 100644
--- a/tsconfig.json
+++ b/tsconfig.json
@@ -1,11 +1,7 @@
{
"compilerOptions": {
"target": "es5",
- "lib": [
- "dom",
- "dom.iterable",
- "esnext"
- ],
+ "lib": ["dom", "dom.iterable", "esnext"],
"allowJs": true,
"skipLibCheck": true,
"strict": true,
@@ -17,28 +13,16 @@
"isolatedModules": true,
"jsx": "preserve",
"incremental": true,
- "types": [
- "cypress",
- "node"
- ],
+ "types": ["cypress", "node"],
"plugins": [
{
"name": "next"
}
],
"paths": {
- "@/*": [
- "./*"
- ]
+ "@/*": ["./*"]
}
},
- "include": [
- "next-env.d.ts",
- "**/*.ts",
- "**/*.tsx",
- ".next/types/**/*.ts"
- ],
- "exclude": [
- "node_modules"
- ]
+ "include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
+ "exclude": ["node_modules"]
}