update dependencies, eslint config

This commit is contained in:
Matt Walsh committed 2026-08-13 15:00:19 -05:00
1 parent 6a557707b7
commit 59a42a951c
4 files changed
+4003 -1335

No files matched your search

-34
View File
@@ -1,34 +0,0 @@
module.exports = {
root: true,
env: {
node: true,
},
extends: 'airbnb-base',
parserOptions: {
ecmaVersion: 2023,
},
rules: {
indent: [
'error',
'tab',
],
'no-tabs': 0,
'max-len': 0,
'no-use-before-define': [
'error',
{
variables: false,
},
],
'import/extensions': [
'error',
{
mjs: 'always',
js: 'never',
},
],
},
ignorePatterns: [
'*.min.js',
],
};
+86
View File
@@ -0,0 +1,86 @@
import path from 'node:path';
import { includeIgnoreFile } from '@eslint/compat';
import js from '@eslint/js';
import { defineConfig } from 'eslint/config';
import { configs, plugins } from 'eslint-config-airbnb-extended';
const gitignorePath = path.resolve('.', '.gitignore');
const jsConfig = defineConfig([
// ESLint recommended config
{
name: 'js/config',
...js.configs.recommended,
},
// Stylistic plugin
plugins.stylistic,
// Import X plugin
plugins.importX,
// Airbnb base recommended config
...configs.base.recommended,
]);
const nodeConfig = defineConfig([
// Node plugin
plugins.node,
// Airbnb Node recommended config
...configs.node.recommended,
]);
const rules = {
'@stylistic/indent': ['error', 'tab', { SwitchCase: 1 }],
'@stylistic/no-tabs': 0,
'no-param-reassign': [
'error',
{
props: false,
},
],
'@stylistic/max-len': 0,
'no-underscore-dangle': [
'error',
{
allowAfterThis: true,
},
],
'import-x/no-useless-path-segments': 0,
'no-bitwise': 0,
'import-x/extensions': [
'error',
'ignorePackages',
{
js: 'always',
mjs: 'always',
json: 'always',
},
],
};
const languageOptions = {
ecmaVersion: 'latest',
parserOptions: {
ecmaVersion: 'latest',
},
};
const ignores = [
'docs/**',
];
export default defineConfig([
{
ignores,
},
// Ignore files and folders listed in .gitignore
includeIgnoreFile(gitignorePath),
// JavaScript config
...jsConfig,
// Node config
...nodeConfig,
{
languageOptions,
rules,
},
]);
+3903 -1293
View File
File diff suppressed because it is too large. Load diff
+14 -8
View File
@@ -5,7 +5,8 @@
"main": "src/index.mjs",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"lint": "eslint"
"lint": "npx eslint .",
"lint:fix": "npx eslint . --fix"
},
"repository": {
"type": "git",
@@ -26,16 +27,21 @@
},
"homepage": "https://github.com/netbymatt/nexrad-level-3-plot#readme",
"devDependencies": {
"eslint": "^8.0.0",
"eslint-config-airbnb-base": "^15.0.0",
"eslint-plugin-import": "^2.22.1"
"@eslint/compat": "^2.1.0",
"@eslint/js": "^9.39.5",
"eslint": "^9.39.5",
"eslint-config-airbnb-extended": "^3.1.1"
},
"dependencies": {
"canvas": "^2.6.1",
"glob": "^10.4.1",
"nexrad-level-3-data": "^0.6.0"
"canvas": "^3.0.0",
"glob": "^13.0.0",
"nexrad-level-3-data": "^1.0.0"
},
"engines": {
"node": ">=14.0.0"
"node": ">=24.0.0"
},
"allowScripts": {
"canvas@3.2.3": true,
"unrs-resolver@1.12.2": true
}
}