Тайлбар байхгүй

xiongzhu c02c01159d 换域名 2 сар өмнө
.docker 04f78a30e0 init 4 сар өмнө
.github 04f78a30e0 init 4 сар өмнө
.zed 04f78a30e0 init 4 сар өмнө
handlebarsHelpers 04f78a30e0 init 4 сар өмнө
nginx_conf f7e89dbae5 . 2 сар өмнө
public c02c01159d 换域名 2 сар өмнө
rlottie_with_printf 04f78a30e0 init 4 сар өмнө
snapshot-server 04f78a30e0 init 4 сар өмнө
src 5885a9eca9 更新版本信息至2.2 (597),修改公共文件引用的脚本路径,调整 API 基础 URL 格式。 2 сар өмнө
.editorconfig 04f78a30e0 init 4 сар өмнө
.env c02c01159d 换域名 2 сар өмнө
.env.local.example 04f78a30e0 init 4 сар өмнө
.gitignore 72704600a1 更新版本信息,修改 API 基础 URL,优化语言包中的文本内容,移除不必要的文件和代码,清理旧的会话数据,确保用户体验流畅。 3 сар өмнө
.gitmodules 04f78a30e0 init 4 сар өмнө
CHANGELOG.md 04f78a30e0 init 4 сар өмнө
CHANGELOG_ru.md 04f78a30e0 init 4 сар өмнө
LICENSE 04f78a30e0 init 4 сар өмнө
README.md 04f78a30e0 init 4 сар өмнө
SECURITY.md 04f78a30e0 init 4 сар өмнө
babel.config.js 04f78a30e0 init 4 сар өмнө
build.js 04f78a30e0 init 4 сар өмнө
deploy.js b65d83a87e . 2 сар өмнө
deploy.sh 8a051dc16d deploy 3 сар өмнө
docker-compose.yaml 04f78a30e0 init 4 сар өмнө
eslint.config.mjs 04f78a30e0 init 4 сар өмнө
fff.code-workspace 04f78a30e0 init 4 сар өмнө
git-serve-server.js 04f78a30e0 init 4 сар өмнө
git-serve.js 04f78a30e0 init 4 сар өмнө
index.html 04f78a30e0 init 4 сар өмнө
keepAsset.js 04f78a30e0 init 4 сар өмнө
package.json bb4cdf0bf7 更新依赖项版本,简化自动登录服务,添加自动登录页面 4 сар өмнө
pnpm-lock.yaml bb4cdf0bf7 更新依赖项版本,简化自动登录服务,添加自动登录页面 4 сар өмнө
schema.js 04f78a30e0 init 4 сар өмнө
server.js 04f78a30e0 init 4 сар өмнө
ssh.example.json 04f78a30e0 init 4 сар өмнө
sw.ts 04f78a30e0 init 4 сар өмнө
tsconfig.json 04f78a30e0 init 4 сар өмнө
vite.config.ts 04f78a30e0 init 4 сар өмнө
vite.proxy.js 04f78a30e0 init 4 сар өмнө
watch-lang.js 04f78a30e0 init 4 сар өмнө

README.md

Telegram Web K

Based on Webogram, patched and improved. Available for everyone here: https://web.telegram.org/k/

Developing

Install dependencies with:

pnpm install

This will install all the needed dependencies.

Running web-server

Just run pnpm start to start the web server and the livereload task. Open http://localhost:8080/ in your browser.

Running in production

Run node build to build the minimized production version of the app. Copy public folder contents to your web server.

Running in docker

Developing:

  • Install dependencies docker-compose up tweb.dependencies.
  • Run develop container docker-compose up tweb.develop.
  • Open http://localhost:8080/ in your browser.

Production:

  • Run docker-compose up tweb.production -d nginx image and container to serve the build
  • Open http://localhost:80/ in your browser.

I also created an image https://hub.docker.com/r/elgammalx/tweb/tags based on Nginx ready to be deployed.

You can use docker build -f ./.docker/Dockerfile_production -t {dockerhub-username}/{imageName}:{latest} . to build your production ready image.

My build use in docker-compose.yaml file

services:
  tweb.production:
    image: elgammalx/tweb
    ports:
      - 80:80

Dependencies

Debugging

You are welcome in helping to minimize the impact of bugs. There are classes, binded to global context. Look through the code for certain one and just get it by its name in developer tools. Source maps are included in production build for your convenience.

Additional query parameters

  • test=1: to use test DCs
  • debug=1: to enable additional logging
  • noSharedWorker=1: to disable Shared Worker, can be useful for debugging
  • http=1: to force the use of HTTPS transport when connecting to Telegram servers

Should be applied like that: http://localhost:8080/?test=1

Taking local storage snapshots

You can also take and load snapshots of the local storage and indexed DB using the ./snapshot-server mini-app. Check the README.md under this folder for more details.

Preview all icons

You can see all the available svg icons by calling the showIconLibrary() global function in the browser's console.

Troubleshooting & Suggesting

If you find an issue with this app or wish something to be added, let Telegram know using the Suggestions Platform.

Licensing

The source code is licensed under GPL v3. License is available here.