Skip to content

Commit

Permalink
Merge pull request #665 from aryaemami59/remove-svg-requires
Browse files Browse the repository at this point in the history
  • Loading branch information
markerikson authored Dec 17, 2023
2 parents 150d3c5 + 355da53 commit 50c7a56
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 11 deletions.
1 change: 0 additions & 1 deletion website/docusaurus.config.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import type { Options, ThemeConfig } from '@docusaurus/preset-classic'
import type { Config } from '@docusaurus/types'
import { themes as prismThemes } from 'prism-react-renderer'

const config: Config = {
title: 'Reselect',
Expand Down
12 changes: 2 additions & 10 deletions website/src/components/HomepageFeatures/index.tsx
Original file line number Diff line number Diff line change
@@ -1,19 +1,17 @@
import Heading from '@theme/Heading'
import clsx from 'clsx'
import type { ComponentProps, ComponentType, FC } from 'react'
import type { FC } from 'react'
import { memo } from 'react'
import styles from './styles.module.css'

interface FeatureItem {
title: string
Svg: ComponentType<ComponentProps<'svg'>>
description: JSX.Element
}

const FeatureList: FeatureItem[] = [
{
title: 'Predictable',
Svg: require('@site/static/img/undraw_docusaurus_mountain.svg').default,
description: (
<>
Like Redux, Reselect gives users a <b>consistent mental model</b> for
Expand All @@ -24,7 +22,6 @@ const FeatureList: FeatureItem[] = [
},
{
title: 'Optimized',
Svg: require('@site/static/img/undraw_docusaurus_tree.svg').default,
description: (
<>
Reselect{' '}
Expand All @@ -38,7 +35,6 @@ const FeatureList: FeatureItem[] = [
},
{
title: 'Customizable',
Svg: require('@site/static/img/undraw_docusaurus_react.svg').default,
description: (
<>
Reselect comes with fast defaults, but provides{' '}
Expand All @@ -49,7 +45,6 @@ const FeatureList: FeatureItem[] = [
},
{
title: 'Type-Safe',
Svg: require('@site/static/img/undraw_docusaurus_react.svg').default,
description: (
<>
Reselect is designed for <b>great TypeScript support</b>. Generated
Expand All @@ -59,12 +54,9 @@ const FeatureList: FeatureItem[] = [
}
]

const Feature: FC<FeatureItem> = memo(({ title, Svg, description }) => {
const Feature: FC<FeatureItem> = memo(({ title, description }) => {
return (
<div className={clsx('col col--3')}>
<div className="text--center">
{/* <Svg className={styles.featureSvg} role="img" /> */}
</div>
<div className="text--center padding-horiz--md">
<Heading as="h3">{title}</Heading>
<p>{description}</p>
Expand Down

0 comments on commit 50c7a56

Please sign in to comment.