refactor: sort typescript imports

This commit is contained in:
Sam 2022-12-22 15:49:08 +01:00
parent 7bb179a2dc
commit cd7689d0f5
No known key found for this signature in database
GPG Key ID: B4EF20DDE721CAA1
9 changed files with 33 additions and 24 deletions

View File

@ -1,12 +1,13 @@
import { useEffect, useState } from "react";
import { MoonStars, Sun, List } from "react-bootstrap-icons";
import { List, MoonStars, Sun } from "react-bootstrap-icons";
import Link from "next/link";
import NavItem from "./NavItem";
import Logo from "./logo";
import { useRecoilState } from "recoil";
import { APIError, ErrorCode, fetchAPI, MeUser } from "../lib/api-fetch";
import { themeState, userState } from "../lib/state";
import { fetchAPI, APIError, ErrorCode, MeUser } from "../lib/api-fetch";
import Logo from "./logo";
import NavItem from "./NavItem";
export default function Navigation() {
const [user, setUser] = useRecoilState(userState);

View File

@ -1,8 +1,5 @@
import Head from "next/head";
import ReactMarkdown from "react-markdown";
import { userState } from "../lib/state";
import { useRecoilValue } from "recoil";
import FallbackImage from "./FallbackImage";
import React from "react";
import {
EmojiLaughing,
HandThumbsDown,
@ -10,10 +7,14 @@ import {
HeartFill,
People,
} from "react-bootstrap-icons";
import BlueLink from "./BlueLink";
import React from "react";
import Card from "./Card";
import ReactMarkdown from "react-markdown";
import { useRecoilValue } from "recoil";
import { Field, Label, LabelStatus, Person, User } from "../lib/api";
import { userState } from "../lib/state";
import BlueLink from "./BlueLink";
import Card from "./Card";
import FallbackImage from "./FallbackImage";
export default function PersonPage({ person }: { person: Person }) {
return (

View File

@ -1,9 +1,11 @@
import "../styles/globals.css";
import type { AppProps } from "next/app";
import Head from "next/head";
import { RecoilRoot } from "recoil";
import Container from "../components/Container";
import Navigation from "../components/Navigation";
import { RecoilRoot } from "recoil";
import Head from "next/head";
function MyApp({ Component, pageProps }: AppProps) {
const domain =

View File

@ -1,14 +1,15 @@
import { useEffect, useState } from "react";
import { useRouter } from "next/router";
import { useEffect, useState } from "react";
import { useRecoilState } from "recoil";
import { userState } from "../../lib/state";
import TextInput from "../../components/TextInput";
import Loading from "../../components/Loading";
import Button, { ButtonStyle } from "../../components/Button";
import Notice from "../../components/Notice";
import BlueLink from "../../components/BlueLink";
import toast from "../../lib/toast";
import Button, { ButtonStyle } from "../../components/Button";
import Loading from "../../components/Loading";
import Notice from "../../components/Notice";
import TextInput from "../../components/TextInput";
import { fetchAPI, MeUser, SignupResponse } from "../../lib/api-fetch";
import { userState } from "../../lib/state";
import toast from "../../lib/toast";
interface CallbackResponse {
has_account: boolean;

View File

@ -1,7 +1,8 @@
import { GetServerSideProps } from "next";
import Head from "next/head";
import { useRouter } from "next/router";
import { useRecoilValue } from "recoil";
import Head from "next/head";
import { fetchAPI } from "../../lib/api-fetch";
import { userState } from "../../lib/state";

View File

@ -1,6 +1,7 @@
import { useRouter } from "next/router";
import { useEffect } from "react";
import { useRecoilState } from "recoil";
import Loading from "../components/Loading";
import { userState } from "../lib/state";

View File

@ -1,9 +1,9 @@
import { GetStaticProps } from "next";
import { readdirSync } from "fs";
import ReactMarkdown from "react-markdown";
import { readFile } from "fs/promises";
import { join } from "path";
import { GetStaticProps } from "next";
import Head from "next/head";
import { join } from "path";
import ReactMarkdown from "react-markdown";
export async function getStaticPaths() {
const names = readdirSync("./static_pages").filter((name) =>

View File

@ -1,4 +1,5 @@
import { GetServerSideProps } from "next";
import PersonPage from "../../../components/PersonPage";
import { Member } from "../../../lib/api";
import * as API from "../../../lib/api-fetch";

View File

@ -1,4 +1,5 @@
import { GetServerSideProps } from "next";
import PersonPage from "../../../components/PersonPage";
import { User } from "../../../lib/api";
import * as API from "../../../lib/api-fetch";