Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ permissions:
on:
push:
branches:
- "**"
- main
pull_request:
branches:
- "**"
- main
workflow_dispatch:

jobs:
Expand All @@ -23,7 +23,6 @@ jobs:
strategy:
matrix:
node-version:
- 18.x
- 20.x
- 22.x

Expand Down
54 changes: 35 additions & 19 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -1,23 +1,39 @@
import { defineConfig, globalIgnores } from "eslint/config";
import globals from "globals";
import globals from 'globals'

export default defineConfig([globalIgnores(["src/**/*.test.js"]), {
languageOptions: {
globals: {
...globals.browser,
...globals.node,
Atomics: "readonly",
SharedArrayBuffer: "readonly",
export default [
{
ignores: [
'node_modules/**',
'coverage/**'
],
},
{
files: ['src/**/*.js'],
languageOptions: {
globals: {
...globals.browser,
...globals.node,
Atomics: 'readonly',
SharedArrayBuffer: 'readonly',
},
},

ecmaVersion: 8,
sourceType: "commonjs",
},
rules: {
// Code style - match TypeScript settings
semi: ['error', 'never'],
quotes: ['error', 'single'],

rules: {
"no-unused-vars": ["warn", {
argsIgnorePattern: "^_",
varsIgnorePattern: "^_",
}],
},
}]);
// Strict checking - match TypeScript strictness
'no-console': 'warn',
'no-unused-vars': 'warn', // Match TypeScript noUnusedLocals: true
'no-undef': 'error',
strict: ['error', 'global'], // Match TypeScript alwaysStrict: true

// Additional strictness to match TypeScript behavior
'no-implicit-globals': 'error',
'prefer-const': 'error', // Encourage immutability
'no-var': 'error', // Use let/const only
'no-redeclare': 'error'
}
}
]
8 changes: 0 additions & 8 deletions jest.config.js

This file was deleted.

15 changes: 15 additions & 0 deletions jest.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
export default {
collectCoverage: true,
coverageDirectory: 'coverage',
testEnvironment: 'jsdom',
testEnvironmentOptions: {
customExportConditions: ['node']
},
setupFilesAfterEnv: ["./test/helpers/jest.setup.js"],
transformIgnorePatterns: ["/node_modules/(?!lit-html).+\\.js"],
roots: ['<rootDir>/src', '<rootDir>/test'],
moduleNameMapper: {
'^SolidLogic$': 'solid-logic',
'^\\$rdf$': 'rdflib'
},
}
Loading