Skip to content

Commit

Permalink
ncu, newer eslint config
Browse files Browse the repository at this point in the history
  • Loading branch information
lexoyo committed Dec 15, 2024
1 parent 709ff25 commit 6c5980e
Show file tree
Hide file tree
Showing 4 changed files with 62 additions and 35 deletions.
20 changes: 0 additions & 20 deletions .eslintrc.json

This file was deleted.

44 changes: 44 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
import typescriptEslint from "@typescript-eslint/eslint-plugin";
import globals from "globals";
import tsParser from "@typescript-eslint/parser";
import path from "node:path";
import { fileURLToPath } from "node:url";
import js from "@eslint/js";
import { FlatCompat } from "@eslint/eslintrc";

const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
const compat = new FlatCompat({
baseDirectory: __dirname,
recommendedConfig: js.configs.recommended,
allConfig: js.configs.all
});

export default [
...compat.extends("eslint:recommended", "plugin:@typescript-eslint/recommended"),
{
plugins: {
"@typescript-eslint": typescriptEslint,
},

languageOptions: {
globals: {
...globals.browser,
...globals.node,
},

parser: tsParser,
ecmaVersion: 5,
sourceType: "module",
},

rules: {
indent: ["error", 2],
"linebreak-style": ["error", "unix"],
quotes: ["error", "single"],
semi: ["error", "never"],
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": ["error"],
},
},
];
31 changes: 17 additions & 14 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,35 +27,38 @@
"test:watch": "$npm_execpath run test -- --watch"
},
"devDependencies": {
"@eslint/eslintrc": "^3.2.0",
"@eslint/js": "^9.17.0",
"@jest/globals": "^29.7.0",
"@typescript-eslint/eslint-plugin": "^7.7.0",
"@typescript-eslint/parser": "^7.7.0",
"eslint": "^8.57.0",
"@typescript-eslint/eslint-plugin": "^8.18.0",
"@typescript-eslint/parser": "^8.18.0",
"eslint": "^9.17.0",
"globals": "^15.13.0",
"jest": "^29.7.0",
"jest-environment-jsdom": "^29.7.0",
"node_modules-path": "^2.0.8",
"nodemon": "^3.1.0",
"ts-jest": "^29.1.2"
"nodemon": "^3.1.9",
"ts-jest": "^29.2.5"
},
"peerDependencies": {
"@silexlabs/silex": "*",
"grapesjs": "^0.21.10",
"lit-html": "^3.0.2"
},
"dependencies": {
"@rollup/plugin-commonjs": "^25.0.7",
"@humanwhocodes/retry": "^0.4.1",
"@rollup/plugin-commonjs": "^28.0.1",
"@rollup/plugin-eslint": "^9.0.5",
"@rollup/plugin-json": "^6.1.0",
"@rollup/plugin-node-resolve": "^15.2.3",
"@rollup/plugin-typescript": "^11.1.6",
"rollup": "^4.14.3",
"rollup-plugin-tslint": "^0.2.2",
"typescript": "^5.4.5",
"tslib": "^2.6.2",
"@humanwhocodes/retry": "^0.3.0",
"@rollup/plugin-node-resolve": "^15.3.0",
"@rollup/plugin-typescript": "^12.1.1",
"@silexlabs/grapesjs-data-source": "^0.0.122",
"dedent": "^1.5.3",
"deepmerge": "^4.3.1"
"deepmerge": "^4.3.1",
"rollup": "^4.28.1",
"rollup-plugin-tslint": "^0.2.2",
"tslib": "^2.8.1",
"typescript": "^5.7.2"
},
"author": "lexoyo",
"license": "MIT",
Expand Down
2 changes: 1 addition & 1 deletion src/client/liquid.ts
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ function handleFilterOption(filter: Filter, key: string, value: string): string
.join('.')
return filter.quotedOptions?.includes(key) ? quote(result) : result
}
} catch (e) {
} catch {
// Ignore
}
return filter.quotedOptions?.includes(key) ? quote(value) : value
Expand Down

0 comments on commit 6c5980e

Please sign in to comment.