Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 0 additions & 25 deletions .eslintignore

This file was deleted.

93 changes: 0 additions & 93 deletions .eslintrc.json

This file was deleted.

2 changes: 1 addition & 1 deletion .lintstagedrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ module.exports = {
"**/*.{js,ts,jsx,tsx}": async (files) => {
const filesToLint = await removeIgnoredFiles(files);

return [`eslint -c .eslintrc.json --max-warnings=0 --fix ${filesToLint}`];
return [`eslint --max-warnings=0 --fix ${filesToLint}`];
},
"**/*.css": async (files) => {
const filesToLint = await removeIgnoredFiles(files);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* eslint-disable no-console */
"use client";

import * as React from "react";
Expand Down
1 change: 0 additions & 1 deletion apps/docs/app/examples/table/custom-styles/page.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* eslint-disable jsx-a11y/no-onchange */
"use client";

import {
Expand Down
1 change: 0 additions & 1 deletion apps/docs/app/examples/table/use-case/page.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* eslint-disable jsx-a11y/no-onchange */
"use client";

import {
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/components/ads/carbon-ad/carbon-ad.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ export const CarbonAd: React.FC<unknown> = () => {
setShowEthicalAds(true);
}
});
} catch (error) {
} catch {
loadCarbonAds();
}
} else {
Expand Down
1 change: 0 additions & 1 deletion apps/docs/components/ads/carbon-ad/carbon-optimize.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ export default {

if (!document.hidden) {
if (typeof _carbonads !== "undefined" && isElementInViewport("#carbonads")) {
// eslint-disable-next-line no-undef
_carbonads.refresh();
}
}
Expand Down
1 change: 0 additions & 1 deletion apps/docs/components/blog/video-in-view.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* eslint-disable jsx-a11y/media-has-caption */
"use client";

import {useInView} from "framer-motion";
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/components/cmdk.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ export const Cmdk: FC<{}> = () => {
[query],
);

const items = !isEmpty(results) ? results : recentSearches ?? [];
const items = !isEmpty(results) ? results : (recentSearches ?? []);

// Toggle the menu when ⌘K / CTRL K is pressed
useEffect(() => {
Expand Down
4 changes: 2 additions & 2 deletions apps/docs/components/docs/components/code-demo/code-demo.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@ const DynamicReactLiveDemo = dynamic(
() => import("./react-live-demo").then((m) => m.ReactLiveDemo),
{
ssr: false,
// eslint-disable-next-line react/display-name

loading: () => <Skeleton className="w-full h-24 rounded-xl" />,
},
);

const DynamicSandpack = dynamic(() => import("../../../sandpack").then((m) => m.Sandpack), {
ssr: false,
// eslint-disable-next-line react/display-name

loading: () => <Skeleton className="w-full h-32 rounded-xl" />,
});

Expand Down
1 change: 0 additions & 1 deletion apps/docs/components/marketing/a11y-otb.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
"use client";

/* eslint-disable react/display-name */
import {
Button,
Image,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
"use client";

/* eslint-disable react/display-name */
import {useMemo, useState} from "react";
import {Tabs, Tab, Card, CardBody, Image, Button, RadioGroup, Radio} from "@heroui/react";
import NextLink from "next/link";
Expand Down
1 change: 0 additions & 1 deletion apps/docs/components/marketing/customization.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
"use client";

/* eslint-disable react/display-name */
import {Button, Link} from "@heroui/react";
import NextLink from "next/link";

Expand Down
1 change: 0 additions & 1 deletion apps/docs/components/marketing/dark-mode.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
"use client";

/* eslint-disable react/display-name */
import {Code, Button, Tooltip} from "@heroui/react";
import {useState} from "react";
import NextLink from "next/link";
Expand Down
2 changes: 0 additions & 2 deletions apps/docs/components/marketing/last-but-not-least.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
/* eslint-disable react/display-name */

import {title, subtitle, titleWrapper, sectionWrapper} from "@/components/primitives";
import {FeaturesGrid} from "@/components/marketing/features-grid";
import landingContent from "@/content/landing";
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/components/marketing/support.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ async function getData() {
return {
sponsors,
};
} catch (error) {
} catch {
throw new Error("Failed to fetch data");
}
}
Expand Down
1 change: 0 additions & 1 deletion apps/docs/components/mdx-components.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* eslint-disable react/display-name */
import {clsx} from "@heroui/shared-utils";
import * as Components from "@heroui/react";
import {Language} from "prism-react-renderer";
Expand Down
1 change: 0 additions & 1 deletion apps/docs/hooks/use-scroll-position.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* eslint-disable no-undef */
import * as React from "react";

export function useScrollPosition(ref: React.MutableRefObject<HTMLElement | null>) {
Expand Down
1 change: 0 additions & 1 deletion apps/docs/hooks/use-scroll-spy.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* eslint-disable no-undef */
import * as React from "react";

export function useScrollSpy(selectors: string[], options?: IntersectionObserverInit) {
Expand Down
1 change: 0 additions & 1 deletion apps/docs/hooks/use-update-effect.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ export const useUpdateEffect: typeof useEffect = (effect, deps) => {
return effect();
}
effectCycleRef.current = true;
// eslint-disable-next-line react-hooks/exhaustive-deps
}, deps);

useEffect(() => {
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/libs/github/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export interface GithubError extends Error {
function getErrorText(res: Response) {
try {
return res.text();
} catch (err) {
} catch {
return res.statusText;
}
}
Expand Down
1 change: 0 additions & 1 deletion apps/docs/libs/rehype-highlight-line.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ const lineNumberify = function lineNumberify(ast, lineNum = 1) {
const lines = node.value.split("\n");

for (let i = 0; i < lines.length; i++) {
// eslint-disable-next-line no-plusplus
if (i !== 0) ++lineNumber;
if (i === lines.length - 1 && lines[i].length === 0) continue;
result.nodes.push({
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/scripts/build-sponsors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ async function build() {
// make sure the sponsors directory exists
try {
await fs.access(sponsorsDir);
} catch (error) {
} catch {
await fs.mkdir(sponsorsDir, { recursive: true });
}
await Promise.all([buildSponsors()])
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/scripts/update-github-info.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ async function getGithubInfo() {
};

// Format JSON with prettier
const formattedJson = prettier.format(JSON.stringify(githubInfo), {
const formattedJson = await prettier.format(JSON.stringify(githubInfo), {
parser: 'json',
printWidth: 80,
tabWidth: 2,
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/scripts/update-search-meta.ts
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ async function getSearchMeta(saveMode: "algolia" | "local" = "local") {
try {
result = await getMDXMeta(file);
json.push(...result);
} catch (error) {}
} catch {}
}

if (saveMode === "local") {
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/utils/get-sponsors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export const getSponsors = async () => {
);

return sponsors as Sponsor[];
} catch (error) {
} catch {
return __PROD__ ? [] : mockData;
}
};
Loading