mirror of
https://github.com/sergeyyarkov/devthread.ru.git
synced 2026-10-11 10:19:13 +03:00
prop types
This commit is contained in:
parent
8345fbeb56
commit
f15a73bd76
@ -1,4 +1,5 @@
|
||||
import React from 'react';
|
||||
import PropTypes from 'prop-types'
|
||||
import { useLocation } from '@reach/router'
|
||||
import { Link } from 'gatsby'
|
||||
import slugify from '../../../helpers/slugify'
|
||||
@ -14,3 +15,7 @@ const CategoryItem = ({ title }) => {
|
||||
|
||||
export default CategoryItem
|
||||
|
||||
CategoryItem.propTypes = {
|
||||
title: PropTypes.string
|
||||
}
|
||||
|
||||
|
||||
@ -1,4 +1,5 @@
|
||||
import React from 'react'
|
||||
import PropTypes from 'prop-types'
|
||||
|
||||
const Search = ({ articlesLength }) => {
|
||||
return (
|
||||
@ -10,3 +11,7 @@ const Search = ({ articlesLength }) => {
|
||||
}
|
||||
|
||||
export default Search
|
||||
|
||||
Search.propTypes = {
|
||||
articlesLength: PropTypes.number
|
||||
}
|
||||
@ -1,4 +1,5 @@
|
||||
import React from 'react';
|
||||
import PropTypes from 'prop-types'
|
||||
import slugify from '../../helpers/slugify'
|
||||
import Img from "gatsby-image"
|
||||
import './Books.scss'
|
||||
@ -18,3 +19,9 @@ const Books = ({ data: { edges } }) => {
|
||||
}
|
||||
|
||||
export default Books
|
||||
|
||||
Books.propTypes = {
|
||||
data: PropTypes.shape({
|
||||
edges: PropTypes.array
|
||||
})
|
||||
}
|
||||
@ -1,4 +1,5 @@
|
||||
import React from 'react';
|
||||
import PropTypes from 'prop-types'
|
||||
import { Link } from 'gatsby'
|
||||
import slugify from '../../../helpers/slugify'
|
||||
|
||||
@ -11,3 +12,7 @@ const BookItem = ({ title }) => {
|
||||
}
|
||||
|
||||
export default BookItem
|
||||
|
||||
BookItem.propTypes = {
|
||||
title: PropTypes.string
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user