updating test page to use backend post
This commit is contained in:
parent
ff364f661e
commit
86a5d4da74
|
|
@ -1,13 +1,12 @@
|
||||||
import Menu from "../components/ui/Menu";
|
import Menu from "../components/ui/Menu";
|
||||||
import { postGameStatisticsData } from "../services/WordpressFetchData";
|
import { postGameStatisticsData, postGameStatisticsDataBackend } from "../services/WordpressFetchData";
|
||||||
import { useLanguage } from "../hooks/useLanguage";
|
import { useLanguage } from "../hooks/useLanguage";
|
||||||
import { useEffect } from "react";
|
import { useEffect } from "react";
|
||||||
|
|
||||||
export default function Test() {
|
export default function Test() {
|
||||||
const { language } = useLanguage();
|
const { language } = useLanguage();
|
||||||
|
|
||||||
function addPost() {
|
function postStatistics() {
|
||||||
postGameStatisticsData(language);
|
postGameStatisticsDataBackend();
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
@ -16,8 +15,8 @@ export default function Test() {
|
||||||
<div className='screen screen--test'>
|
<div className='screen screen--test'>
|
||||||
<Menu />
|
<Menu />
|
||||||
<div id='screen-container'>
|
<div id='screen-container'>
|
||||||
<button onClick={() => addPost()}>static data function Finish the game</button>
|
<button onClick={postStatistics}> Test throught backend</button>
|
||||||
<button onClick={() => test()}>Finish the game</button>
|
{/* <button onClick={() => addPost()}>static data function Finish the game</button> */}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user