import React, { Component } from "react"; export class ToggleButton extends Component { state={ surah:true, chapter:false, checkBtn:true } toggleChapter = ()=>{ this.setState({ surah:false, chapter:true, checkBtn:false }) } toggleSurah = ()=>{ this.setState({ surah:true, chapter:false, checkBtn:true }) } render() { const showSurah = (

Al-Faatiha (الفاتحة){" "} The Opener

Details: Makkan / Ayat: 7 / Num: 1

Al-Faatiha (الفاتحة){" "} The Opener

Details: Makkan / Ayat: 7 / Num: 1

Al-Faatiha (الفاتحة){" "} The Opener

Details: Makkan / Ayat: 7 / Num: 1
); const showChapter = (

not Hello

); return (
{ this.state.surah ? showSurah : showChapter }
); } } export default ToggleButton;