MCPcopy Create free account
hub / github.com/1Panel-dev/1Panel / normalizeEditorExtension

Function normalizeEditorExtension

frontend/src/utils/file.ts:164–170  ·  view source on GitHub ↗
(value: string)

Source from the content-addressed store, hash-verified

162const specialEditorFileNames = ['dockerfile'];
163
164const normalizeEditorExtension = (value: string) => {
165 const trimmed = value.trim().toLowerCase();
166 if (!trimmed) {
167 return '';
168 }
169 return trimmed.startsWith('.') ? trimmed.slice(1) : trimmed;
170};
171
172const isSpecialEditorFileName = (value: string) => {
173 const normalized = value.trim().toLowerCase();

Callers 1

resolveEditorLanguageFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected