Projetos
Sobre
npm package for TWA SDK
Ferramentas de desenvolvimentoCrescimento medido de estrelas
- em 24 h
- 0
- em 7 dias
- 0
- em 15 dias
- 0
- em 1 mês
- Coletando histórico
Variações líquidas em períodos sobrepostos, não totais diários. Medições ausentes ficam em branco. Estrelas indicam interesse, não qualidade.
README.md
OriginalSDK
npm package for Telegram Web Apps (TWA) SDK.
npm i @twa-dev/sdk
Motivation
Telegram distributes SDK via link. It's kinda old fashion way to work with a library:
<html lang="en">
<head>
<title>TWA</title>
<meta charset="UTF-8">
<script src="https://telegram.org/js/telegram-web-app.js?56"></script>
<script>
window.Telegram.WebApp.showAlert('Hey there!');
</script>
</head>
<body></body>
</html>
This package allows to work with SDK as with a npm package:
import WebApp from '@twa-dev/sdk'
WebApp.showAlert('Hey there!');
And yes, it supports TS.
Demo
React
If you use React in your project, check out components that we have prepared for you.
These components significantly simplify developer experience.
Explore projetos relacionados
Carregando…