VS Code 编辑器未显示正确的主题。有时它工作,有时不工作,我不知道如何重现它。我卸载了 VS Code 并再次安装它,但我仍然无法调试自己的主题。
我创建了一个新的颜色主题
$ yo code
我选择new color theme
并选择了blank dark one
.
现在,当我启动调试器时,它会加载一个带有我的主题的新编辑器。我可以在preferences
和的菜单中选择它color theme
。
然后有时它不会应用选定的更改。
但是当我从那时删除所有内容时,tokenColors: [...]
它让我再次选择颜色主题,但是当我在 tokenColors 中键入一些新主题并重新加载它时,它不会应用新样式。
我的猜测是 VS Code 将样式缓存在某处并且不会覆盖它。
问题是如果无法调试,我该如何开发新的颜色主题?
如何重新加载主题?
{
"name": "T",
"type": "dark",
"colors": {
"editorGroup.background": "#2b303b",
"editorGroup.border": "#c0c5ce",
"editor.background": "#2b303b",
"editor.foreground": "#c0c5ce",
"activityBarBadge.background": "#2b303b",
"sideBar.background": "#1c1f26",
"sideBar.foreground": "#c0c5ce",
"list.hoverBackground": "#2b303b",
"list.hoverForeground": "#c0c5ce",
"list.activeSelectionForeground": "#c0c5ce",
"list.inactiveSelectionForeground": "#c0c5ce",
"list.activeSelectionBackground": "#2b303b",
"list.inactiveSelectionBackground": "#2b303b",
"sideBarTitle.foreground": "#c0c5ce",
"sideBarSectionHeader.background": "#2b303b",
"statusBar.background": "#1c1f26",
"statusBar.foreground": "#c0c5ce",
"tab.activeBackground": "#2b303b",
"tab.inactiveBackground": "#1c1f26",
"terminal.background": "#2b303b",
"activityBar.border": "#1c1f26",
"activityBar.background": "#2b303b",
"sideBar.border": "#1c1f26",
"tab.activeForeground": "#c0c5ce"
},
"tokenColors": [
{
// const, let, if, else, async, await, try, catch
"name": "j",
"scope": [
"storage.type.js.jsx",
"storage.modifier.async.js.jsx",
"keyword.control.flow.js.jsx",
"keyword.control.conditional.js.jsx",
"keyword.control.trycatch.js.jsx"
],
"settings": {
"foreground": "#b48ead",
"fontStyle": "italic"
}
}
]
}