0.1.29 • Published 10 months ago

@taole/smallgames v0.1.29

Weekly downloads
-
License
-
Repository
-
Last release
10 months ago

数字炸弹说明

https://y-test.tuwan.com/smallGameTips_numBomb https://y-test.tuwan.com/smallGameTips_numBomb

弹幕答题说明

https://y.tuwan.com/smallGameTips_question https://y.tuwan.com/smallGameTips_question

项目介绍

小游戏, 同时支持h5 和 web端npm

项目地址

本地开发环境:https://y-dev.tuwan.com/chartRoom/smallgames

测试环境地址:https://y-test.tuwan.com/smallgames

线上环境地址:https://y.tuwan.com/smallgames

技术栈

svelte、webpack

svelte 官网 webpack 文档地址

项目启动

  • npm i 安装依赖
  • npm run dev 本地开发 访问地址: https://y-dev.tuwan.com:8080/
  • npm run build 打包构建
  • npm run start 运行打包后的项目

跑起不起来用yarn node 版本 16.13.1

其他

  1. 项目支持ts, <script type="ts"> 就可以启用 ts 检测
  2. 打包的配置就一个webpack.config.ts
  3. div 添加点击事件 会报错, 必须给 div 添加 role="presentation"; 这是因为 svelte 的特殊性导致的
  4. 发布npm的时候执行:npm publish --access public

使用

正常npm 安装, 注意样式的引入:

@import "dd-games/public/build/bundle.css"; 

发布测试环境

每次发布请更新版本号(package.json#version)

构建web独立版本(移动端App使用)
1. npm run build 产物在dist目录下 2. 将 dist/assets/* 复制到项目 Staticsmallgames/assets/下, 更新至Static项目的master分支即可(本质是将构建产物放至cdn, 更新之后10s左右即可访问, 路径: https://asset.tuwan.com/smallgames/assets/xxx) 3. 将 dist/index.html的文件内容 覆盖项目 OfficialSite中的 smallgames.htm, 注意OfficialSite项目要使用自己的功能 分支。 同时手动更新测试环境服务器 192.168.0.35@root:/home/web/website/tuwan_www/templets/static/play/smallgames.htm

发布对应npm包(PC web大厅使用) 1. npm run build-npm 产物在npm目录下 2. npm publish 3. 发布完成之后,修改项目ChatRoomSvelteNew中package.json中@taole/smallgames的版本为本次更新的最新版本,更新至其分支master-test-1023 然后在流水线触发ChatRoomSvelteNew-Test

发布到线上

基本类似发布到测试环境

TODO

  • 脚本发布测试环境
0.1.10

10 months ago

0.1.12

10 months ago

0.1.13

10 months ago

0.1.14

10 months ago

0.1.15

10 months ago

0.1.27

10 months ago

0.1.28

10 months ago

0.1.29

10 months ago

0.1.20

10 months ago

0.1.21

10 months ago

0.1.22

10 months ago

0.1.23

10 months ago

0.1.24

10 months ago

0.1.25

10 months ago

0.1.26

10 months ago

0.1.16

10 months ago

0.1.8

10 months ago

0.1.17

10 months ago

0.1.18

10 months ago

0.1.19

10 months ago

0.1.9

10 months ago

0.1.2

11 months ago

0.1.7

11 months ago

0.1.4

11 months ago

0.1.3

11 months ago

0.1.6

11 months ago

0.1.5

11 months ago

0.1.1

1 year ago

0.0.23

1 year ago

0.0.22

1 year ago

0.0.21

1 year ago

0.0.18

1 year ago

0.0.17

1 year ago

0.0.16

1 year ago

0.0.14

1 year ago

0.0.13

1 year ago

0.0.12

1 year ago

0.0.11

1 year ago

0.0.9

1 year ago

0.0.8

1 year ago

0.0.7

1 year ago

0.0.5

1 year ago

0.0.4

1 year ago

0.0.3

1 year ago

0.0.2

1 year ago