Answered step by step
Verified Expert Solution
Question
1 Approved Answer
the file ` speak . page.jsx ` will execute. Currently the component renders a Failed message. You need to update the ` speak ` function
the file speakpage.jsx will execute. Currently the component renders a "Failed" message. You need to update the speak function such that the component renders that a "Passed" message. You can only edit the code inside the speak where indicated and nowhere else.
code
eslintdisable
The only code you may write in this file is inside the speak function.
Add the necessary code in the speak function so that the page displays a "Passed" message.
const log clearLogs, getLogs
let logs ;
return
log: msg logspushmsg
clearLogs:
logs ;
getLogs: logs
;
;
export default function SpeakPage
clearLogs;
speakhello hey, sup
helloragnar;
heylagertha;
;
speaksup
supfloki;
;
speakking greeting, your, majesty, sup
exec king, greeting, your, majesty, sup ;
;
function exec king, greeting, your, majesty, sup
kingecbertgreetingyourmajesty;
kingharaldsup;
const logsAreCorrect
getLogsjoin
hello ragnar
hey lagertha
sup floki
king ecbert greeting your majesty
king harald sup;
return
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started