修改設定以關閉不必要的檔案監控(例如 Laravel 專案中的 vendor 或 node_modules)
- 按下快捷鍵 Ctrl + Shift + P(Mac 為 Cmd + Shift + P)開啟命令面板。
- 輸入 settings json,並選擇 「偏好設定: 開啟遠端設定 (JSON)」 (Preferences: Open Remote Settings (JSON))。
- 在大括號 {} 內貼上以下代碼(如果已有其他設定,記得在前面加上逗號 ,):
{
"files.watcherExclude": {
"**/.git/objects/**": true,
"**/.git/subtree-cache/**": true,
"**/node_modules/*/**": true,
"**/vendor/**": true,
"**/storage/framework/cache/**": true,
"**/storage/logs/**": true
}
}
精簡遠端外掛
原則是:「把視覺、主題、前端工具留在本地;只把後端語法分析(PHP/Docker)裝在遠端」。這樣可以省下極多記憶體。
