Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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 this issue Oct 16, 2024 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@iftekharalammithu
Copy link

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

@iftekharalammithu iftekharalammithu added the bug Something isn't working label Oct 16, 2024
@Shivam1337
Copy link

Same issue here
any solutions

@iftekharalammithu
Copy link
Author

Same issue here any solutions

After researching, I discovered that in the same project, the <script src="https://telegram.org/js/telegram-web-app.js"></script>. And @telegram-apps/sdk cannot be used.

@Shivam1337
Copy link

not using

<script src="https://telegram.org/js/telegram-web-app.js"></script>

only using @tonconnect/ui

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants