1
+ const posts = [
2
+ {
3
+ title : 'Our Legendary Article here' ,
4
+ href : '#' ,
5
+ category : { name : 'Greatness' , href : '#' } ,
6
+ description :
7
+ 'Reactime v17, we have come a long way from beta. Now introducing full Context API support and CustomHooks support: thereby allowing developers to better visualize the states and ... ' ,
8
+ date : 'Dec 14, 2022' ,
9
+ datetime : '2022-12-14' ,
10
+ imageUrl :
11
+ 'https://images.unsplash.com/photo-1496128858413-b36217c2ce36?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=crop&w=1679&q=80' ,
12
+ readingTime : '6 min' ,
13
+ author : {
14
+ name : 'James Nghiem' ,
15
+ href : '#' ,
16
+ imageUrl :
17
+ 'https://images.unsplash.com/photo-1472099645785-5658abf4ff4e?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=facearea&facepad=2&w=256&h=256&q=80' ,
18
+ } ,
19
+ } ,
20
+ {
21
+ title : 'Time-Traveling Through React State' ,
22
+ href : 'https://rxlina.medium.com/time-traveling-through-react-state-with-reactime-9-0-371dbdc99319' ,
23
+ category : { name : 'React' , href : '#' } ,
24
+ description :
25
+ 'Reactime is a Chrome extension and time-travel debugger for React that allows developers to record, track, and visualize state changes. Reactime leverages React’s core reconciliation... ' ,
26
+ date : 'Oct 7, 2021' ,
27
+ datetime : '2020-10-07' ,
28
+ imageUrl :
29
+ 'https://images.unsplash.com/photo-1547586696-ea22b4d4235d?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=crop&w=1679&q=80' ,
30
+ readingTime : '4 min' ,
31
+ author : {
32
+ name : 'Lina Shin' ,
33
+ href : 'https://rxlina.medium.com/' ,
34
+ imageUrl :
35
+ 'https://media-exp1.licdn.com/dms/image/C5603AQHQGFvRHt25WQ/profile-displayphoto-shrink_200_200/0/1623865299399?e=1676505600&v=beta&t=yDqgIaJOhO3oOWLROIH9rHPBHdVzDSV3VlB2axWqXr4' ,
36
+ } ,
37
+ } ,
38
+ {
39
+ title : 'Open Source DeBugging Tool for React' ,
40
+ href : 'https://betterprogramming.pub/time-traveling-state-with-reactime-6-0-53fdc3ae2a20' ,
41
+ category : { name : 'Better Programming' , href : '#' } ,
42
+ description :
43
+ 'State management is a crucial part of developing efficient and performant React applications. Developers know that managing state can become unmanageable as an application scales... ' ,
44
+ date : 'Oct 21, 2020' ,
45
+ datetime : '2020-10-21' ,
46
+ imageUrl :
47
+ 'https://images.unsplash.com/photo-1492724441997-5dc865305da7?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=crop&w=1679&q=80' ,
48
+ readingTime : '11 min' ,
49
+ author : {
50
+ name : 'Vincent Nguyen' ,
51
+ href : 'https://medium.com/@CSVince' ,
52
+ imageUrl :
53
+ 'https://media-exp1.licdn.com/dms/image/C5603AQEsAdcE-e7kZg/profile-displayphoto-shrink_200_200/0/1604336802983?e=1676505600&v=beta&t=yK3edcZkpG4Yhvr4iavafRs1SBEQgza-4IRJncRV0X4' ,
54
+ } ,
55
+ } ,
56
+ ]
57
+
58
+ export default function Blogs ( ) {
59
+ return (
60
+ < div className = "relative bg-gray-50 px-4 pt-16 pb-20 sm:px-6 lg:px-8 lg:pt-24 lg:pb-28" >
61
+ < div className = "absolute inset-0" >
62
+ < div className = "h-1/3 bg-white sm:h-2/3" />
63
+ </ div >
64
+ < div className = "relative mx-auto max-w-7xl" >
65
+ < div className = "text-center" >
66
+ < h2 className = "text-3xl font-bold tracking-tight text-gray-900 sm:text-4xl" > From the blog</ h2 >
67
+ < p className = "mx-auto mt-3 max-w-2xl text-xl text-gray-500 sm:mt-4" >
68
+ See the blogs from the most recent updates and to the past years!
69
+ </ p >
70
+ </ div >
71
+ < div className = "mx-auto mt-12 grid max-w-lg gap-5 lg:max-w-none lg:grid-cols-3" >
72
+ { posts . map ( ( post ) => (
73
+ < div key = { post . title } className = "flex flex-col overflow-hidden rounded-lg shadow-lg" >
74
+ < div className = "flex-shrink-0" >
75
+ < img className = "h-48 w-full object-cover" src = { post . imageUrl } alt = "" />
76
+ </ div >
77
+ < div className = "flex flex-1 flex-col justify-between bg-white p-6" >
78
+ < div className = "flex-1" >
79
+ < p className = "text-sm font-medium text-indigo-600" >
80
+ < a href = { post . category . href } className = "hover:underline" >
81
+ { post . category . name }
82
+ </ a >
83
+ </ p >
84
+ < a href = { post . href } className = "mt-2 block" >
85
+ < p className = "text-xl font-semibold text-gray-900" > { post . title } </ p >
86
+ < p className = "mt-3 text-base text-gray-500" > { post . description } </ p >
87
+ </ a >
88
+ </ div >
89
+ < div className = "mt-6 flex items-center" >
90
+ < div className = "flex-shrink-0" >
91
+ < a href = { post . author . href } >
92
+ < span className = "sr-only" > { post . author . name } </ span >
93
+ < img className = "h-10 w-10 rounded-full" src = { post . author . imageUrl } alt = "" />
94
+ </ a >
95
+ </ div >
96
+ < div className = "ml-3" >
97
+ < p className = "text-sm font-medium text-gray-900" >
98
+ < a href = { post . author . href } className = "hover:underline" >
99
+ { post . author . name }
100
+ </ a >
101
+ </ p >
102
+ < div className = "flex space-x-1 text-sm text-gray-500" >
103
+ < time dateTime = { post . datetime } > { post . date } </ time >
104
+ < span aria-hidden = "true" > ·</ span >
105
+ < span > { post . readingTime } read</ span >
106
+ </ div >
107
+ </ div >
108
+ </ div >
109
+ </ div >
110
+ </ div >
111
+ ) ) }
112
+ </ div >
113
+ </ div >
114
+ </ div >
115
+ )
116
+ }
0 commit comments