Here's what happens when I change from sandbox to level 1:
email/get?level=0 returns all the sent emails in the session for given level.
openai/history?level=0 returns the chat history in the session for given level.
defence/status?level=0 returns the defences as configured for given level.
These three are also called when you refresh.
🔧 These should be combined.
AC:
GIVEN frontend in preview mode (so that react doesn't do its double render thing) npm run preview
WHEN the user changes from one level to another (check specifically switching in and out of sandbox)
THEN there should be only one api call made of type fetch
Here's how you quickly find out in Chrome what api calls are being made that are fetch type. Note that the CombinedFonts call is of type xhr, therefore we ignore it.
Here's what happens when I change from sandbox to level 1:
email/get?level=0
returns all the sent emails in the session for given level.openai/history?level=0
returns the chat history in the session for given level.defence/status?level=0
returns the defences as configured for given level.These three are also called when you refresh.
🔧 These should be combined.
AC:
GIVEN frontend in preview mode (so that react doesn't do its double render thing)
npm run preview
WHEN the user changes from one level to another (check specifically switching in and out of sandbox) THEN there should be only one api call made of type fetchHere's how you quickly find out in Chrome what api calls are being made that are fetch type. Note that the CombinedFonts call is of type xhr, therefore we ignore it.