I'm trying to make my font size larger while working in VSCode. I go to the view tab, choose appearances, then "zoom in", but it keeps giving me this error message: "Unable to write into user settings. Please open the user settings to correct errors/warnings in it and try again." I clicked on the "Open Settings" button and it took me to {}settings.json, but I have no idea what errors to look for or what needs to be corrected. I should have said that I'm working on an iMac. Does anyone know what needs to be changed or inserted? Here are the json settings:
"workbench.activityBar.visible": true,
"workbench.sideBar.location": "right",
"terminal.integrated.shell.osx": "/bin/bash",
"python.terminal.executeInFileDir": true,
"[python]": {
},
"editor.suggestSelection": "first",
"vsintellicode.modify.editor.suggestSelection":
"automaticallyOverrodeDefaultValue",
"java.semanticHighlighting.enabled": true,
"workbench.editorAssociations": [
{
"viewType": "jupyter.notebook.ipynb",
"filenamePattern": "*.ipynb"
}
],
"python.languageServer": "Microsoft",
"extensions.ignoreRecommendations": true,
"files.defaultLanguage": "python",
Related
The LiveServer in my VSCode is somehow not working correctly and stably, I have to manually refresh. I can say that I tried all the solutions I found, but I could not get a definite result. Below I am sharing the settings.json, I hope I can find a solution with your help.
{
"typescript.validate.enable": false,
"javascript.validate.enable": false,
"workbench.colorTheme": "One Dark Pro",
"liveServer.settings.donotVerifyTags": true,
"liveServer.settings.donotShowInfoMsg": true,
"editor.wordWrap": "on",
"files.exclude": {
"**/.git": false
},
"liveServer.settings.ChromeDebuggingAttachment": false,
"liveServer.settings.useWebExt": false,
"liveServer.settings.CustomBrowser": "chrome",
"liveServer.settings.port": 0,
"window.zoomLevel": 0,
"workbench.startupEditor": "none",
"emmet.useInlineCompletions": true,
"[html]": {
"editor.defaultFormatter": "vscode.html-language-features"
},
"[css]": {
"editor.defaultFormatter": "vscode.css-language-features"
},
"workbench.iconTheme": "vscode-icons",
"[javascript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
}
Besides this problem, I also started getting Uncaught Error in Console, it doesn't block the stream, but it's annoying to just sit there. The error I get is as follows:
Uncaught (in promise) Error: "undefined" is not valid JSON
at A (content.js:1:9544)
Even if this 2nd problem is not solved, I will be very happy if I can find a solution for LiveServer.
It could be caused by a browser plugin cause. I had this problem too, but after uninstall this plugin, it was fixed:
I have been searching web for a long for a correct way to use vscode editor for PHP debug and get confused with lot of result. When I run > start debug F5 from menu on vscode within a php page I am getting this prompt
when I click the edit in settings.json, I am getting this
{
"workbench.colorTheme": "Solarized Dark",
"workbench.editorAssociations": {
"*.ipynb": "jupyter-notebook"
},
"editor.suggestSelection": "first",
"vsintellicode.modify.editor.suggestSelection": "automaticallyOverrodeDefaultValue",
"workbench.startupEditor": "none",
"[php]": {
"editor.defaultFormatter": "kokororin.vscode-phpfmt"
},
"notebook.cellToolbarLocation": {
"default": "right",
"jupyter-notebook": "left"
},
"editor.fontSize": 15,
"editor.cursorBlinking": "smooth",
"editor.cursorSmoothCaretAnimation": true,
"editor.formatOnType": true,
"auto-close-tag.fullMode": true,
"auto-close-tag.insertSpaceBeforeSelfClosingTag": true,
"auto-close-tag.SublimeText3Mode": true,
"python.languageServer": "None",
"html.format.templating": true
}
Now from web search I found I must add this line to the above json script
"php.validate.executablePath": "C:xampp/php/php.exe"
My php has also successfully running xdebug which I manage to start with help of web search. Now only thing which I miss (hope so) is to add the above path to vscode setting which I don't know where to add. Please help me to get this to get done. Thanks in advance.
I am using VSCode autoimport on daily basis with this extension
soates autoimport.
https://github.com/soates/Auto-Import/issues/104.
It suddenly stopped to work. I have tried reinstall vscode, changing extension version, disabling plugins, clearing cache ...etc
I have tried this https://www.youtube.com/watch?v=1yu5tB4KOis and also tried add
checkjs: true to my jsconfig.json. Its very hard to live without auto import.
these are my settings.json
{
"dart.flutterSdkPath": "C:\\Users\\rolni\\AppData\\Roaming\\flutter_windows_v1.12.13+hotfix.9-stable\\flutter\\bin",
"explorer.confirmDelete": false,
"workbench.colorCustomizations": {
"[Material Theme Darker]": {
"statusBar.debuggingBackground": "#212121"
}
},
"material-icon-theme.folders.associations": {
"global_state": "global",
"ui": "layout",
"bloc": "controller"
},
"workbench.iconTheme": "material-icon-theme",
"debug.node.autoAttach": "on",
"[json]": {
"editor.quickSuggestions": {
"strings": true
},
"editor.suggest.insertMode": "replace",
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"typescript.updateImportsOnFileMove.enabled": "always",
"notebook.kernelProviderAssociations": [],
"emmet.triggerExpansionOnTab": true,
"emmet.showSuggestionsAsSnippets": true,
"editor.snippetSuggestions": "top",
"explorer.confirmDragAndDrop": false,
"javascript.updateImportsOnFileMove.enabled": "always",
"highlight-matching-tag.customEmptyElements": null,
"emmet.excludeLanguages": [
"markdown"
],
"emmet.includeLanguages": {
"javascript": "html"
},
"autoimport.filesToScan": "**/*.{ts,tsx,js,jsx}",
"autoimport.showNotifications": true,
"extensions.ignoreRecommendations": true,
"workbench.editor.enablePreview": false,
"outline.showVariables": false,
"debug.javascript.autoAttachFilter": "disabled",
"debug.javascript.terminalOptions": {
"trace": true
},
"[javascript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[jsonc]": {
"editor.defaultFormatter": "vscode.json-language-features"
},
"terminal.integrated.shell.windows": "C:\\Program Files\\PowerShell\\7-preview\\pwsh.exe",
"debug.onTaskErrors": "debugAnyway",
"[go]": {
"editor.insertSpaces": false
},
"go.formatTool": "gofmt",
"go.useLanguageServer": true,
"gopls": {
"usePlaceholders": true, // add parameter placeholders when completing a function
},
"todo-tree.tree.showScanModeButton": false,
"todo-tree.highlights.customHighlight": {
"TODO": {
"icon": "check",
"type": "line",
"iconColour": "yellow",
"foreground": "red",
"background": "yellow"
},
"FIXME": {
"icon": "beaker",
"iconColour": "red",
"foreground": "white",
"background": "red"
}
},
"debug.inlineValues": true,
"editor.codeActionsOnSave": {
"source.organizeImports": true
},
"[typescriptreact]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"tabnine.experimentalAutoImports": true,
"gitlens.hovers.currentLine.over": "line",
"terminal.integrated.tabs.enabled": true,
"go.toolsManagement.autoUpdate": true,
"workbench.colorTheme": "Material Theme",
"git.enableSmartCommit": true,
"todo-tree.general.tags": [
"BUG",
"HACK",
"FIXME",
"TODO",
"XXX",
"[ ]",
"[x]"
],
"todo-tree.regex.regex": "(//|#|<!--|;|/\\*|^|^\\s*(-|\\d+.))\\s*($TAGS)",
"terminal.integrated.defaultProfile.windows": "PowerShell",
"editor.formatOnSave": true,
}
Can't also debug extension all my breakpoints are unbound...can't figure out how to debug it to find root cause of problem.
This log is in my output Log (Extension Host)
[error] [vscode.json-language-features] provider FAILED
[2021-07-05 13:23:44.550] [exthost] [error] Canceled: Canceled
at b.makeCancelError (c:\Users\rolni\AppData\Local\Programs\Microsoft VS Code\resources\app\extensions\json-language-features\client\dist\node\jsonClientMain.js:1:64563)
at b.handleFailedRequest (c:\Users\rolni\AppData\Local\Programs\Microsoft VS Code\resources\app\extensions\json-language-features\client\dist\node\jsonClientMain.js:1:64414)
at c:\Users\rolni\AppData\Local\Programs\Microsoft VS Code\resources\app\extensions\json-language-features\client\dist\node\jsonClientMain.js:1:24756
EDIT:
I have tried remove plugins, directories, settings, but still
autoimport extension is not enabled even it says yes. Its even missing
the log in extension host output.
For JavaScript projects
VSCode in general starts to fail after a while, it OFTEN doesn't suggest imports from package dependencies and even starts to stop hinting auto import for local project src folder files...
As soon as you open the file it will all of a sudden become available...
It's not a plugin issue, it's just VS code, it's starting to get bloated...
For TypeScript projects
It's not so bad, they seem mainly focused on TS these days, but when it goes wrong it goes wrong. I've started un-installing, go to install folders make sure nothing is there and re-install and it works again. No login sync.
Alternative (which I am not a fan off but just works... grrr)
PHPStorm / WebStorm, it gets the import right every time.
And ctrl click on sub methods of class's will auto open that file and locate you on that method. VSCode will just open that file, if it can find it...
With auto complete (in JS Projects) on variables assigned to a class. I think VS Code will only do that if the file is open in the editor.
I keep both open now, VSCode for speed of editing but when (not if) VSCode start to play up, I switch over. Also for the stacking of file tabs feature in PHPStorm instead of a scroll bar of tabs. I find it easier to just switch over to PHPStorm and back again instead of that scroll thing.
After latest VS-Code update, tab feature changes to "focus change" instead of adding space or identation. i try change every setting in setting.json but it not wotrking. it is really annoying as i am use to it.
Any Help would be appreciated.
{
"workbench.iconTheme": "material-icon-theme",
"editor.formatOnSave": true,
"prettier.singleQuote": true,
"workbench.startupEditor": "newUntitledFile",
"window.zoomLevel": 0,
"indenticator.hover.peekBack": 0,
"indenticator.hover.peekForward": 1,
"indenticator.inner.hover.peekBack": 0,
"indenticator.inner.hover.peekForward": 1,
"indenticator.inner.showHighlight": true,
"html.format.endWithNewline": true,
"javascript.implicitProjectConfig.experimentalDecorators": true,
"prettier.printWidth": 110,
"html.format.indentHandlebars": true,
"html.format.indentInnerHtml": true,
"liveServer.settings.AdvanceCustomBrowserCmdLine": "C:\\Program Files\\Firefox Developer Edition\\firefox.exe",
"prettier.jsxBracketSameLine": true,
"prettier.trailingComma": "es5",
"prettier.useTabs": true,
"angular2-switcher.openSideBySide": true,
"editor.foldingStrategy": "indentation",
"editor.mouseWheelZoom": true,
"[html]": {
"editor.defaultFormatter": "HookyQR.beautify"
},
"[less]": {
"editor.defaultFormatter": "michelemelluso.code-beautifier"
},
"workbench.statusBar.visible": true,
"workbench.activityBar.visible": true,
"editor.renderControlCharacters": false,
"editor.showFoldingControls": "always",
"editor.smoothScrolling": true,
"breadcrumbs.enabled": false,
"terminal.integrated.rendererType": "dom",
"[javascript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[jsonc]": {
"editor.defaultFormatter": "HookyQR.beautify"
},
"terminal.integrated.shell.windows": "C:\\WINDOWS\\System32\\WindowsPowerShell\\v1.0\\powershell.exe"
}
This is my settings file. Extensions settings are same as before.
In the command palette, use Toggle Tab Key Moves Focus (Ctrl + M by default as of 1.36.0) to switch between these modes.
While backing up my VS-Code settings on cloud i found (in C:\Users\[username]\AppData\Roaming\Code\User > keybindings.json) that tab was assigned as -tab labeled to move-focus. which did'nt appear on UI settings on Vs-Code.
i dont know where it came from (after 2nd Last VS-Code Update):
{
"key": "tab",
"command": "-tab",
"when": "editorTextFocus && !editorReadonly && !editorTabMovesFocus"
}
i just removed it . And it Works same as DEFAULT.
Sharing this as answer if anyone faces this problem from nowhere.
Thank You. :)
This might be a superuser question, apologizes if it is.
I keep getting a few errors in netbeans (my IDE) which uses typescript and angular2 plugins
The errors I'm getting:
"Experimental support for decorators is a feature...."
and
"Cannot find name 'Promise'"
Even though i get these errors, everything works fine. So I'm just looking for a way to remove them showing up, I've read a bit about some ts.config, but I can't find that file..
My project structure looks like this:
I've found the ts.config
It was just not an "important file" I guess ;-)
Though it seems to have no effect:
{
"compilerOptions": {
"allowSyntheticDefaultImports": true,
"declaration": false,
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"lib": [
"dom",
"es2015"
],
"module": "es2015",
"moduleResolution": "node",
"sourceMap": true,
"target": "es5"
},
"include": [
"src/**/*.ts"
],
"exclude": [
"node_modules"
],
"compileOnSave": false,
"atom": {
"rewriteTsconfig": false
}
}
There is currently No solution to the problem with netbeans plugins.
I've changed to Visual Studio Code, which offers a good typescript compiler.