ton-connect / sdk

SDK for TON Connect 2.0 — a comprehensive communication protocol between wallets and apps in TON ecosystem
Apache License 2.0
326 stars 92 forks source link

Access to resource at 'https://connect.tonhubapi.com/tonconnect/events?client_id=e23a2bdca0189e5cd7d6e38f5cda1f899dfcc5d66843c6de0aee46500fb784437' from origin 'https://telegram-gaaming-app.vercel.app' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. #269

Open iftekharalammithu opened 1 month ago

iftekharalammithu commented 1 month ago

Describe the bug

I Set the the code as Documentation the app is working good the Payments and transactions are also working great. but when i inspect the app i figure out This Error Continuously Show up

Access to resource at 'https://connect.tonhubapi.com/tonconnect/events?client_id=e23a2bdca0189e5cd7d6e38f5cda1f899dfcc5d66843c6de0aee46500fb784437' from origin 'https://telegram-gaaming-app.vercel.app' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.

Is there any Way to Fix This . My Application Is in Reactjs Vite

Expected behavior

The Error show This "blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource." I Think i Have to config my Domain in @tonconnect/ui-react Library. But How can i do that?

Current behavior

I Did lots of things as per research in google but not successful

Steps to Reproduce

  1. make a app in Reactjs Vite
  2. Add Payment Features @tonconnect/ui-react and @ton
  3. after that if open Inspect you will find the Error

Environment

Brave Browser

Additional context

No response

Shivam1337 commented 1 month ago

Same issue here any solutions

iftekharalammithu commented 4 weeks ago

Same issue here any solutions

After researching, I discovered that in the same project, the . And @telegram-apps/sdk cannot be used.

Shivam1337 commented 4 weeks ago

not using

only using @tonconnect/ui