thinkphp6 does not take effect immediately after modifying the code
Add the following code to index.php in the public directory
//处理调试模式下,文件修改不能即时生效问题,实际使用时2~5为最佳 - 上线记得去掉
ini_set('opcache.revalidate_freq',0);
If you are using mac mamp pro
The following cache needs to be turned off
If you can modify the php configuration file (I have not tried this)
Modify the php configuration file opcache.revalidate_freq=0;