Skip to content

Commit

Permalink
feat: Install prettier-plugin-organize-imports infiniflow#1842
Browse files Browse the repository at this point in the history
  • Loading branch information
cike8899 committed Sep 10, 2024
1 parent 04accd1 commit 99ce4b4
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 23 deletions.
7 changes: 7 additions & 0 deletions gui/.prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"arrowParens": "always",
"singleQuote": true,
"tabWidth": 2,
"trailingComma": "none",
"plugins": ["prettier-plugin-organize-imports"]
}
16 changes: 0 additions & 16 deletions gui/app/(dashboard)/database/page.tsx
Original file line number Diff line number Diff line change
@@ -1,26 +1,10 @@
import { Tabs, TabsContent, TabsList, TabsTrigger } from '@/components/ui/tabs';
import { File, PlusCircle } from 'lucide-react';
import { Button } from '@/components/ui/button';

export default async function ProductsPage({
searchParams
}: {
searchParams: { q: string; offset: string };
}) {
const search = searchParams.q ?? '';
const offset = searchParams.offset ?? 0;
// const { products, newOffset, totalProducts } = await getProducts(
// search,
// Number(offset)
// );

const ret = await fetch('http://localhost:3000/products');
const products = await ret.json();

const { newOffset, totalProducts } = {
newOffset: 0,
totalProducts: 0
};

return <div>database</div>;
}
9 changes: 2 additions & 7 deletions gui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,9 @@
"typescript": "5.5.3",
"zod": "^3.23.8"
},
"prettier": {
"arrowParens": "always",
"singleQuote": true,
"tabWidth": 2,
"trailingComma": "none"
},
"devDependencies": {
"@svgr/webpack": "^8.1.0",
"code-inspector-plugin": "^0.16.1"
"code-inspector-plugin": "^0.16.1",
"prettier-plugin-organize-imports": "^4.0.0"
}
}
21 changes: 21 additions & 0 deletions gui/pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 99ce4b4

Please sign in to comment.