{"id":20732418,"url":"https://github.com/jpush/jchat-web","last_synced_at":"2025-04-23T22:20:35.510Z","repository":{"id":31712435,"uuid":"35278208","full_name":"jpush/jchat-web","owner":"jpush","description":"JChat web","archived":false,"fork":false,"pushed_at":"2019-04-18T10:05:27.000Z","size":18885,"stargazers_count":103,"open_issues_count":0,"forks_count":35,"subscribers_count":18,"default_branch":"master","last_synced_at":"2025-03-30T04:05:25.725Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://jchat.im.jiguang.cn","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jpush.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-05-08T12:31:44.000Z","updated_at":"2024-09-07T09:40:35.000Z","dependencies_parsed_at":"2022-09-10T09:10:25.018Z","dependency_job_id":null,"html_url":"https://github.com/jpush/jchat-web","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpush%2Fjchat-web","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpush%2Fjchat-web/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpush%2Fjchat-web/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpush%2Fjchat-web/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jpush","download_url":"https://codeload.github.com/jpush/jchat-web/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250522833,"owners_count":21444608,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-17T05:19:21.931Z","updated_at":"2025-04-23T22:20:35.488Z","avatar_url":"https://github.com/jpush.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# JChat-web\n![Release](https://img.shields.io/badge/release-1.2.0-blue.svg?style=flat)\n![Support](https://img.shields.io/badge/support-IE11+-blue.svg?style=flat)\n![Language](http://img.shields.io/badge/language-Angular2-brightgreen.svg?style=flat)\n\n\t\t\n### 简介\n\nJChat 是基于 JMessage SDK 带有完整 UI 界面的即时通讯应用。 演示了完整的即时通讯功能，包括：\n\n* 单聊、群聊、会话列表、通讯录、聊天室；\n* 支持发送文本、图片、文件、表情、名片；\n* 提供好友管理、群组管理、黑名单、群屏蔽、消息免打扰、通知栏、消息漫游、消息已读未读、会话置顶、群聊@XXX、多端在线等功能；\n\nJChat 无需成为好友也可以聊天\n\n* 通过搜索对方的用户名可直接发起会话\n\n目前已覆盖 [Android](https://github.com/jpush/jchat-android) 、 [iOS](https://github.com/jpush/jchat-swift) 、[windows](https://github.com/jpush/jchat-windows)和 web 平台，开发者可参照 JChat 快速打造自己的产品，提高开发效率。\n\n![jiguang](./screenshot/webjchat.gif)\n\n### 应用截图\n\n![jiguang](./screenshot/webjchat2.png)\n\n### 在线体验地址\n\n[JChat-web在线体验](https://jchat.im.jiguang.cn/#/login)\n\n### 环境配置\n\n前提：安装 node (node版本6.0以上、 npm版本3.0以上)，安装淘宝镜像cnpm([淘宝镜像安装方法](http://npm.taobao.org/))\n\nweb jchat本地安装和用法：\n```\n终端输入cd jchat-web-master\n```\n```\n终端输入cnpm install\n```\n```\n终端输入npm run dll\n```\n```\n终端输入npm run dev\n```\n打开浏览器输入url地址：\nlocalhost:3000\n\n说明：\n* 如果使用的不是本地localhost服务器，则要在task/webpack.dev.js中的publicPath改成自己的ip和端口，在浏览器输入ip和端口去访问项目\n\n* 应用配置（前端生成签名和服务端生成签名，任选一种方式）：\u003cbr /\u003e\n* 前端生成签名配置：\u003cbr /\u003e\n在src/app/services/common/config.ts中\u003cbr /\u003e\n1、填写appkey以及对应的masterSecret\u003cbr /\u003e\n2、isFrontSignature改为true\u003cbr /\u003e\n\n* 服务端生成签名配置：\u003cbr /\u003e\n在src/app/services/common/config.ts中\u003cbr /\u003e\n1、填写appkey，不填masterSecret，masterSecret放在服务端\u003cbr /\u003e\n2、isFrontSignature改为false\u003cbr /\u003e\n3、填写服务端接口url配置项signatureApiUrl\u003cbr /\u003e\n4、在自己的服务端上开发出生成签名的post类型接口\u003cbr /\u003e\n\n* 服务端生成签名的api详解：\u003cbr /\u003e\n前端接口的调用相关的代码已经写好，开发者只需要配置好signatureApiUrl，并在服务端提供签名api接口即可\u003cbr /\u003e\n服务端接收post请求，收到'Content-Type'为'application/json'的json数据，json数据结构示例如下:\u003cbr /\u003e\n{  \n  timestamp: new Date().getTime(),  \n  appkey: authPayload.appkey,  \n  randomStr: authPayload.randomStr  \n}  \n根据json数据及masterSecret生成签名，返回string类型格式的response给前端\u003cbr /\u003e\n\n* 注意：\n生产环境签名的生成需要在开发者服务端生成，不然存在 masterSecret 暴露的风险\u003cbr /\u003e\n\n* 项目压缩打包并发布(前提：已全局安装gulp (终端输入cnpm install gulp -g))：\n\n1. 在task/webpack.prod.js中的publicPath改成'./'\n2. 终端输入gulp noqiniu-prod生成dist文件夹\n3. 将dist目录下的所有文件上传到自己服务器上\n\n### 备注说明\n\n* 整个应用使用Angular2 + webpack + gulp的技术栈，使用了Angular2中的ngrx去管理应用状态\n* 浏览器兼容性: IE11+ ， Chrome ， Firefox ， Safari\n\n### JMessage 文档\n\n* [JMessage web 开发指南](https://docs.jiguang.cn/jmessage/client/im_sdk_js_v2/)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjpush%2Fjchat-web","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjpush%2Fjchat-web","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjpush%2Fjchat-web/lists"}