diff --git a/apps/blog/src/app/[category]/[[...slug]]/Meta.tsx b/apps/blog/src/app/[category]/[[...slug]]/Meta.tsx index f1ef6ea..81e92b9 100644 --- a/apps/blog/src/app/[category]/[[...slug]]/Meta.tsx +++ b/apps/blog/src/app/[category]/[[...slug]]/Meta.tsx @@ -1,4 +1,4 @@ -import { PageData } from "@developomp-site/content/src/types/types" +import type { PageData } from "@developomp-site/content/src/types/types" import { faBook, faCalendar, diff --git a/apps/blog/src/app/[category]/[[...slug]]/helper.ts b/apps/blog/src/app/[category]/[[...slug]]/helper.ts index 70f2e0f..a3b881b 100644 --- a/apps/blog/src/app/[category]/[[...slug]]/helper.ts +++ b/apps/blog/src/app/[category]/[[...slug]]/helper.ts @@ -2,7 +2,7 @@ import type { PageData } from "@developomp-site/content/src/types/types" import contentMap from "@/contentMap" -import { Params } from "./page" +import type { Params } from "./page" export enum PageType { POST, diff --git a/apps/blog/src/app/page.tsx b/apps/blog/src/app/page.tsx index ce2dd4a..188ddb3 100644 --- a/apps/blog/src/app/page.tsx +++ b/apps/blog/src/app/page.tsx @@ -1,4 +1,4 @@ -import { Metadata } from "next" +import type { Metadata } from "next" import Home from "./Home" diff --git a/apps/blog/src/components/Card.tsx b/apps/blog/src/components/Card.tsx index 2c4b74f..d61ffb2 100644 --- a/apps/blog/src/components/Card.tsx +++ b/apps/blog/src/components/Card.tsx @@ -1,4 +1,4 @@ -import { ReactNode } from "react" +import type { ReactNode } from "react" interface Props { children?: ReactNode diff --git a/apps/blog/src/components/PostCard.tsx b/apps/blog/src/components/PostCard.tsx index d07e4bd..3dc6090 100644 --- a/apps/blog/src/components/PostCard.tsx +++ b/apps/blog/src/components/PostCard.tsx @@ -1,4 +1,4 @@ -import { PostData } from "@developomp-site/content/src/types/types" +import type { PostData } from "@developomp-site/content/src/types/types" import { faBook, faCalendar, diff --git a/apps/blog/src/components/TagList.tsx b/apps/blog/src/components/TagList.tsx index c182240..30875f6 100644 --- a/apps/blog/src/components/TagList.tsx +++ b/apps/blog/src/components/TagList.tsx @@ -1,4 +1,4 @@ -import { ReactNode } from "react" +import type { ReactNode } from "react" interface Props { children?: ReactNode | undefined diff --git a/apps/portfolio/src/app/page.tsx b/apps/portfolio/src/app/page.tsx index 25dcfcd..3479f32 100644 --- a/apps/portfolio/src/app/page.tsx +++ b/apps/portfolio/src/app/page.tsx @@ -1,6 +1,6 @@ import portfolio from "@developomp-site/content/dist/portfolio.json" import type { PortfolioProject } from "@developomp-site/content/src/types/types" -import { Metadata } from "next" +import type { Metadata } from "next" import Badge from "@/components/Badge" import ProjectCard from "@/components/ProjectCard" diff --git a/apps/portfolio/src/components/ProjectCard/ProjectCard.tsx b/apps/portfolio/src/components/ProjectCard/ProjectCard.tsx index 8e5c36a..8172852 100644 --- a/apps/portfolio/src/components/ProjectCard/ProjectCard.tsx +++ b/apps/portfolio/src/components/ProjectCard/ProjectCard.tsx @@ -1,6 +1,6 @@ import "./style.scss" -import { PortfolioProject } from "@developomp-site/content/src/types/types" +import type { PortfolioProject } from "@developomp-site/content/src/types/types" import Link from "next/link" import Badge from "@/components/Badge" diff --git a/packages/content/src/index.ts b/packages/content/src/index.ts index c1f53da..b308ae8 100644 --- a/packages/content/src/index.ts +++ b/packages/content/src/index.ts @@ -12,7 +12,8 @@ import { mapFilePath, markdownPath, outPath, portfolioFilePath } from "./config" import { fillTags, parseSeries, sortDates } from "./postProcess" import { recursiveParse } from "./recursiveParse" import { saveIndex } from "./searchIndex" -import { ContentMap, ParseMode, PortfolioData, SeriesMap } from "./types/types" +import type { ContentMap, PortfolioData, SeriesMap } from "./types/types" +import { ParseMode } from "./types/types" export const contentMap: ContentMap = { date: {}, diff --git a/packages/content/src/parseMarkdown.ts b/packages/content/src/parseMarkdown.ts index 9341530..cc82e43 100644 --- a/packages/content/src/parseMarkdown.ts +++ b/packages/content/src/parseMarkdown.ts @@ -22,7 +22,8 @@ import remarkRehype from "remark-rehype" import supersub from "remark-supersub" import { unified } from "unified" -import { MarkdownData, ParseMode } from "./types/types" +import type { MarkdownData } from "./types/types" +import { ParseMode } from "./types/types" import { nthIndex } from "./util" const processor = unified() // interface for remark and rehype diff --git a/packages/content/src/recursiveParse/parsePost.ts b/packages/content/src/recursiveParse/parsePost.ts index 22f8c7c..e584454 100644 --- a/packages/content/src/recursiveParse/parsePost.ts +++ b/packages/content/src/recursiveParse/parsePost.ts @@ -2,9 +2,9 @@ import { contentMap } from ".." import { contentDirectoryPath } from "../config" import { generateToc } from "../parseMarkdown" import { addDocument } from "../searchIndex" -import { PostData } from "../types/types" +import type { PostData } from "../types/types" import { writeToFile } from "../util" -import { DataToPass } from "." +import type { DataToPass } from "." export default async function parsePost(data: DataToPass): Promise { const { diff --git a/packages/content/src/recursiveParse/parseProjects.ts b/packages/content/src/recursiveParse/parseProjects.ts index f400f05..726b150 100644 --- a/packages/content/src/recursiveParse/parseProjects.ts +++ b/packages/content/src/recursiveParse/parseProjects.ts @@ -6,7 +6,7 @@ import { portfolioData } from ".." import { contentDirectoryPath, iconsDirectoryPath } from "../config" import { generateToc } from "../parseMarkdown" import { writeToFile } from "../util" -import { DataToPass } from "." +import type { DataToPass } from "." export default async function parseProjects({ urlPath, diff --git a/packages/content/src/recursiveParse/parseSeries.ts b/packages/content/src/recursiveParse/parseSeries.ts index 8bab489..a591cc5 100644 --- a/packages/content/src/recursiveParse/parseSeries.ts +++ b/packages/content/src/recursiveParse/parseSeries.ts @@ -2,9 +2,9 @@ import { contentMap, seriesMap } from ".." import { contentDirectoryPath } from "../config" import { generateToc } from "../parseMarkdown" import { addDocument } from "../searchIndex" -import { PostData } from "../types/types" +import type { PostData } from "../types/types" import { writeToFile } from "../util" -import { DataToPass } from "." +import type { DataToPass } from "." export default async function parseSeries(data: DataToPass): Promise { const { diff --git a/packages/eslint-config/.eslintrc.cjs b/packages/eslint-config/.eslintrc.cjs index 1edaad1..66cd064 100644 --- a/packages/eslint-config/.eslintrc.cjs +++ b/packages/eslint-config/.eslintrc.cjs @@ -22,6 +22,7 @@ module.exports = { "import/no-duplicates": "error", // typescript stuff - "@typescript-eslint/no-non-null-assertion": "off", + "@typescript-eslint/no-non-null-assertion": "off", // https://typescript-eslint.io/rules/no-non-null-assertion + "@typescript-eslint/consistent-type-imports": "error", // https://typescript-eslint.io/rules/consistent-type-imports }, }