如何在 Ionic 构建/运行时强制刷新缓存的源文件? [英] How to force refresh the cached source files upon Ionic build/run?

查看:26
本文介绍了如何在 Ionic 构建/运行时强制刷新缓存的源文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在使用 ionic buildionic run 时遇到了这个随机问题.

I have this random issue with ionic build or ionic run.

我注意到在编译期间它使用了我的源代码的缓存,因此在进行新的更改时它不会反映在重新编译应用程序时.

I've noticed that during compilation it uses the cache of my source code, therefore when making new changes it doesn't reflect upon re-compiling the app.

所以我的问题是,如何清除构建文件的缓存?我试过做 ionic state reset 但它仍然不起作用,也不卸载然后从我的 Android 重新安装应用程序.

So my question is, how can you clear the cache for the build files? I've tried doing ionic state reset but still it doesn't work nor doing uninstall then re-install the app from my Android.

谢谢

推荐答案

我为解决我的问题所做的是重新初始化 Android 平台.

What I did to solve my problem was to do re-initialize the Android platform.

ionic cordova platform remove android 然后ionic cordova platform add android

转到任务管理器并杀死 java se 进程

goto task manager and kill java se process

这篇关于如何在 Ionic 构建/运行时强制刷新缓存的源文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆