I like how in development cocos creator handle different devices and screen sizes in browser mode. But when you build, it creates kinda 2 different version (one for mobile one for desktop). I wish if I could have the development version instead. does anyone have their own way of achieving that? Please, share if you got anything. Thank You.
Custom Web Build Setup
No one replied
So, here’s my solution -
First Build for Desktop
- add Vue in index.html =>
- create style.js file => style.js
- add style.js at the end of index.hml =>
- change index.html =>
<div id="app"> <div id="GameDiv" style="width:400px; height: 600px;"> <canvas id="GameCanvas" :width="gameWidth" :height="gameHeight"></canvas> <div id="splash"> <div class="progress-bar stripes"> <span style="width: 0%"></span> </div> </div> </div> </div>
- add custom style.css for better view => style.css
- place your splash image at the same folder as css.
It’s better if you customized for your needs.