使用 mysql 数据库在 ionic 中托管 PWA [英] Hosting a PWA in ionic with mysql database
问题描述
我有一个 ionic 移动应用程序,并已将其上传到 Playstore.现在我想在一个网站上托管它.我如何使用 ionic 4 和 mysql 做到这一点?
I have a mobile application in ionic and have uploaded it in playstore. Now I want to host it in a website. How do i do that with ionic 4 and mysql?
我曾尝试访问有关 PWA 的 ionic 文档,但他们使用的是 firebase.
I have tried visiting the ionic documentation about PWA but they are using firebase.
ng add @angular/pwa
ionic build --prod --service-worker
ionic build --prod
推荐答案
如果你不需要 Cordova 使用:
if you not need Cordova use:
npm run ionic:build --prod
并将所有内容从 www 文件夹复制到您的 Web 服务器或者如果你需要科尔多瓦然后为网站使用浏览器平台.
and copy all from the www folder to your Web Server or if you need Cordova then Use Browser Platform for websites.
ionic cordova 平台添加浏览器
ionic cordova 构建浏览器 --prod --release
并将所有内容从/platforms/browser/www 文件夹复制到您的 Web 服务器
and copy all from the /platforms/browser/www folder to your Web Server
这篇关于使用 mysql 数据库在 ionic 中托管 PWA的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!