Skip to content

Language specific encoding is not used right on startup #34943

@bpasero

Description

@bpasero

Steps to Reproduce:

  1. let an extension configure a custom encoding for its language, e.g. for markdown via package.json:
"configurationDefaults": {
	"[markdown]": {
		"editor.wordWrap": "on",
		"editor.quickSuggestions": false,
		"files.encoding": "utf16be"
	}
}
  1. open a markdown file (it should show up as garbage)
  2. reload window

=> file is back to UTF-8
=> the encoding configuration is only resolved later after the file has already loaded

Suggest fix is to store the encoding information of the file into storage and restore it after restart from there.

Metadata

Metadata

Assignees

Labels

bugIssue identified by VS Code Team member as probable bugfile-explorerExplorer widget issuesverifiedVerification succeeded

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions