Skip to content

Commit

Permalink
debugging auth data
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-vahn committed Apr 3, 2024
1 parent 627b50c commit 0a32c05
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { useState, useEffect } from 'react';
import { useWeb3ModalAccount } from '@web3modal/ethers/react';
import { useTonWallet } from '@tonconnect/ui-react';
import WebApp from '@twa-dev/sdk';

import './App.css';

Expand All @@ -27,6 +28,11 @@ enum View {
}

function App() {
// DEBUG
const initData = WebApp.initData;

// DEBUG

const [view, setView] = useState<View>(View.LANDING);

const addToHomeScreen = () => {
Expand Down Expand Up @@ -58,7 +64,7 @@ function App() {
const tonWallet = useTonWallet();
useEffect(() => {
// TON Connect
console.log(tonWallet);
// console.log(tonWallet);
}, [tonWallet]);

// Solana Connect
Expand All @@ -74,6 +80,7 @@ function App() {
<div className="skip-button">
<span onClick={skip}>Skip</span>
</div>
{initData}
<div className="avatar">
<img src={avatarScooter} alt="" />
</div>
Expand Down
3 changes: 3 additions & 0 deletions src/main.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ WebApp.ready();
// Expand the Telegram Mini App to full screen
WebApp.expand();

// Authenticate Telegram User
// const initData = WebApp.initData;

// Wallet Connect Config

// 1. Get projectId
Expand Down

0 comments on commit 0a32c05

Please sign in to comment.