64 lines
2.4 KiB
TypeScript
64 lines
2.4 KiB
TypeScript
// *************************************************************************
|
|
// * (C)opyright 2026 by Ruben Carlo Benante *
|
|
// * *
|
|
// * This program is free software; you can redistribute it and/or modify *
|
|
// * it under the terms of the GNU General Public License as published by *
|
|
// * the Free Software Foundation, either version 3 of the License, or *
|
|
// * (at your option) any later version. *
|
|
// * *
|
|
// * This program is distributed in the hope that it will be useful, *
|
|
// * but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
|
// * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
|
// * GNU General Public License for more details. *
|
|
// * *
|
|
// * You should have received a copy of the GNU General Public License *
|
|
// * along with this program. If not, see http://www.gnu.org/licenses/. *
|
|
// * *
|
|
// * Contact author at: *
|
|
// * Ruben Carlo Benante *
|
|
// * rcb@beco.cc *
|
|
// *************************************************************************
|
|
|
|
import obsidianmd from 'eslint-plugin-obsidianmd';
|
|
import globals from 'globals';
|
|
import { globalIgnores, defineConfig } from 'eslint/config';
|
|
|
|
export default defineConfig(
|
|
globalIgnores([
|
|
'node_modules',
|
|
'dist',
|
|
'esbuild.config.mjs',
|
|
'version-bump.mjs',
|
|
'versions.json',
|
|
'build/**',
|
|
'package.json',
|
|
'package-lock.json',
|
|
'tsconfig.json',
|
|
'src/**/*.test.ts',
|
|
]),
|
|
{
|
|
languageOptions: {
|
|
globals: {
|
|
...globals.browser,
|
|
},
|
|
parserOptions: {
|
|
projectService: {
|
|
allowDefaultProject: ['eslint.config.mts', 'manifest.json'],
|
|
},
|
|
tsconfigRootDir: import.meta.dirname,
|
|
extraFileExtensions: ['.json'],
|
|
},
|
|
},
|
|
},
|
|
...obsidianmd.configs.recommended,
|
|
{
|
|
rules: {
|
|
// QualKard and Kanboard are product names, not sentence-case slips.
|
|
'obsidianmd/ui/sentence-case': [
|
|
'warn',
|
|
{ brands: ['QualKard', 'Kanboard'] },
|
|
],
|
|
},
|
|
},
|
|
);
|