atlp-rwanda/atlp-devpulse-fn

View on GitHub
src/components/readMore.tsx

Summary

Maintainability
A
0 mins
Test Coverage
import React, { Children } from 'react'
import { useState } from 'react'

const readMore = ({children }: any) => {
    const [isReadMoreShown, setReadMoreShown] =useState(false)

  return (
    <div className='red-more-read-less'>
        {isReadMoreShown ? children : Children}
        <button>Read More</button>
      
    </div>
  )
}

export default readMore