Skip to content

Commit bbfc605

Browse files
committed
Fix TS
1 parent f6f37b3 commit bbfc605

File tree

9 files changed

+32
-12
lines changed

9 files changed

+32
-12
lines changed

app/api/heap-snapshot/route.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import fs from "node:fs"
22
import os from "node:os"
33
import path from "node:path"
44
import v8 from "node:v8"
5-
import { requireToken } from "api/utils/auth"
5+
import { requireToken } from "~/api/utils/auth"
66

77
export async function GET(request: Request) {
88
requireToken(request)

app/api/reindex/route.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { NextResponse } from "next/server"
2-
import { requireToken } from "api/utils/auth"
2+
import { requireToken } from "~/api/utils/auth"
33
import { upsertByte } from "lib/api/bytes"
44
import { getByteSource, octokit } from "lib/api/github"
55
import { client } from "lib/db"

app/error.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
"use client"
22

33
import Link from "next/link"
4-
import MainLayout from "(main)/layout"
4+
import MainLayout from "~/(main)/layout"
55
import { Button } from "components/Button"
66
import ErrorPage from "components/ErrorPage"
77

app/lib/parser.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import matter from "gray-matter"
22
import remarkParse from "remark-parse"
33
import { Plugin, unified } from "unified"
4-
import { ByteMeta } from "(main)/bytes/types"
4+
import { ByteMeta } from "~/(main)/bytes/types"
55
import remarkStringify from "./remarkStringify.js"
66

77
export const slugify = (str: string) =>

app/not-found.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
"use client"
22

33
import Link from "next/link"
4-
import MainLayout from "(main)/layout"
4+
import MainLayout from "~/(main)/layout"
55
import { Button } from "components/Button"
66
import ErrorPage from "components/ErrorPage"
77

app/rss/feed.json/route.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { getFeed } from "rss/utils"
1+
import { getFeed } from "~/rss/utils"
22

33
export const dynamic = "force-dynamic"
44

app/rss/feed.xml/route.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { getFeed } from "rss/utils"
1+
import { getFeed } from "~/rss/utils"
22

33
export const dynamic = "force-dynamic"
44

app/rss/utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { Feed } from "feed"
22
import { cache } from "react"
3-
import { getAllBytes } from "(main)/bytes/api"
3+
import { getAllBytes } from "~/(main)/bytes/api"
44
import { parseDate } from "lib/date"
55
import { getAllPosts } from "lib/posts"
66
import { siteMeta } from "lib/siteMeta"

tsconfig.json

Lines changed: 24 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
11
{
22
"compilerOptions": {
3-
"baseUrl": "app",
43
"allowJs": true,
54
"esModuleInterop": true,
65
"forceConsistentCasingInFileNames": true,
76
"isolatedModules": true,
87
"jsx": "react-jsx",
9-
"lib": ["dom", "dom.iterable", "esnext"],
8+
"lib": [
9+
"dom",
10+
"dom.iterable",
11+
"esnext"
12+
],
1013
"module": "esnext",
1114
"moduleResolution": "bundler",
1215
"noEmit": true,
@@ -15,7 +18,22 @@
1518
"strict": true,
1619
"target": "esnext",
1720
"incremental": true,
18-
"plugins": [{ "name": "next" }]
21+
"plugins": [
22+
{
23+
"name": "next"
24+
}
25+
],
26+
"paths": {
27+
"~/*": [
28+
"./app/*"
29+
],
30+
"components/*": [
31+
"./app/components/*"
32+
],
33+
"lib/*": [
34+
"./app/lib/*"
35+
]
36+
}
1937
},
2038
"include": [
2139
"next-env.d.ts",
@@ -25,5 +43,7 @@
2543
"**/*.tsx",
2644
"**/*.mdx"
2745
],
28-
"exclude": ["node_modules"]
46+
"exclude": [
47+
"node_modules"
48+
]
2949
}

0 commit comments

Comments
 (0)