Skip to content
This repository was archived by the owner on Feb 15, 2025. It is now read-only.

Commit 8014a51

Browse files
committed
fixed eslint
1 parent 8e4c73a commit 8014a51

File tree

5 files changed

+18
-6
lines changed
  • src/_pages/LandingPage/components
    • HeaderView/components/HeaderTyper/AutoTyper
    • StartCodingView/components/LiveCoder/components
    • StraightforwardView/components/SectionScroller

5 files changed

+18
-6
lines changed

.eslintignore

+5-1
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,8 @@ node_modules
44
jest.config.js
55
jest.config.base.js
66
scripts/
7-
examples/
7+
examples/
8+
build
9+
.docusaurus
10+
docusaurus.config.js
11+
typings

src/_pages/LandingPage/components/HeaderView/components/HeaderTyper/AutoTyper/index.ts

+6-2
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,12 @@ export class AutoTyper {
2525
config = defineConfig(config, {
2626
initialText: '',
2727
delay: 200,
28-
textListener: () => {},
29-
isTypingListener: () => {},
28+
textListener: () => {
29+
/* empty function */
30+
},
31+
isTypingListener: () => {
32+
/* empty function */
33+
},
3034
});
3135
this.config = {
3236
initialText: config.initialText,

src/_pages/LandingPage/components/StartCodingView/components/LiveCoder/components/FrameworkButton/index.tsx

+5-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,11 @@ export type FrameworkButtonProps = {
1414

1515
const FrameworkButton: React.FC<FrameworkButtonProps> = (props) => {
1616
const { logo, color, active, selectable, notSelectableToolTip } = props;
17-
const onClick = props.onClick || (() => {});
17+
const onClick =
18+
props.onClick ||
19+
(() => {
20+
/* empty function */
21+
});
1822

1923
return (
2024
<div

src/_pages/LandingPage/components/StartCodingView/components/LiveCoder/components/LiveCoderReact/index.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import { CodeSectionPropsInterface } from '../../index';
55
import ReactLiveScope from '@theme/ReactLiveScope';
66
import { useEffect, useState } from 'react';
77

8-
interface Props extends CodeSectionPropsInterface {}
8+
type Props = CodeSectionPropsInterface
99

1010
const LiveCoderReact: React.FC<Props> = (props) => {
1111
const { code, theme, transformCode } = props;

src/_pages/LandingPage/components/StraightforwardView/components/SectionScroller/index.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ const SectionScroller: React.FC<Props> = (props) => {
2323
? props.startIndex
2424
: Math.round(sections.length / 2);
2525
const { windowWidth } = useWindowSize();
26-
let sectionContainerRef = useRef(null);
26+
const sectionContainerRef = useRef(null);
2727
const [showTopChevron, setShowTopChevron] = useState(false);
2828
const [showBottomChevron, setShowBottomChevron] = useState(false);
2929

0 commit comments

Comments
 (0)