Skip to content

Commit 73dc270

Browse files
feat: add txt extension to disable syntax highlighting (#386)
* feat: add txt disable syntax highlighting * fix: update txt extension label to Plain text Co-authored-by: Federico Grandi <fgrandi30@gmail.com> Co-authored-by: Federico Grandi <fgrandi30@gmail.com>
1 parent 56dffaa commit 73dc270

File tree

3 files changed

+26
-1
lines changed

3 files changed

+26
-1
lines changed

packages/config/src/lib/base/languages.ts

+14
Original file line numberDiff line numberDiff line change
@@ -366,6 +366,20 @@ export const SUPPORTED_LANGUAGES: readonly LanguageDefinition[] = [
366366
},
367367
],
368368
},
369+
{
370+
id: 'plain-text',
371+
label: 'Plain Text',
372+
color: '#e38c00',
373+
plugin: () => Promise.resolve([]),
374+
icons: [
375+
{
376+
name: 'txt',
377+
extension: '.txt',
378+
content: () => import('../icons/txt.svg?raw'),
379+
matcher: /^.*\.(txt)$/,
380+
},
381+
],
382+
},
369383
{
370384
id: 'json',
371385
label: 'JSON',

packages/config/src/lib/icons/txt.svg

+11
Loading

scripts/patch-solid-exports.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ if (applyPatch) {
2020
console.log('Apply patch');
2121
file.exports = {
2222
'.': {
23-
default: './dist/esm/index.jsx',
23+
default: './dist/esm/index.js',
2424
solid: './dist/source/index.jsx',
2525
},
2626
};

0 commit comments

Comments
 (0)