diff --git a/.eslintrc.json b/.eslintrc.json index e56311c16..436a6fde5 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -1,12 +1,13 @@ { - "ignorePatterns": ["eslint.config.mjs", - "**/build/**", - "**/dist/**", - "**/node_modules/**", - "**/instrumented/**", - "**/coverage/**", - "nyc-config.cjs", - ".lintstagedrc.js", - "cypress.config.js" -] + "ignorePatterns": [ + "eslint.config.mjs", + "**/build/**", + "**/dist/**", + "**/node_modules/**", + "**/instrumented/**", + "**/coverage/**", + "nyc-config.cjs", + ".lintstagedrc.mjs", + "cypress.config.js" + ] } diff --git a/.lintstagedrc.js b/.lintstagedrc.mjs similarity index 100% rename from .lintstagedrc.js rename to .lintstagedrc.mjs diff --git a/cypress.config.js b/cypress.config.js index 2acfd9f95..1fb74be36 100644 --- a/cypress.config.js +++ b/cypress.config.js @@ -1,12 +1,8 @@ /* eslint-disable import-x/no-extraneous-dependencies */ /* eslint-disable import-x/no-default-export */ +const { defineConfig } = require('cypress') -import { defineConfig } from 'cypress' - -import coverage from '@cypress/code-coverage/task' -import plugin from './cypress/plugins/index.js' - -export default defineConfig({ +module.exports = defineConfig({ experimentalStudio: process.env.NODE_ENV === 'development', projectId: 'c3jsph', defaultCommandTimeout: 30000, @@ -18,8 +14,8 @@ export default defineConfig({ // We've imported your old cypress plugins here. // You may want to clean this up later by importing these. setupNodeEvents(on, config) { - coverage(on, config) - plugin(on, config) + require('@cypress/code-coverage/task')(on, config) + require('./cypress/plugins/index.js')(on, config) return config }, baseUrl: 'http://localhost:3000', diff --git a/eslint.config.mjs b/eslint.config.mjs index 281f4e3c0..6d50a45bb 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -23,7 +23,7 @@ export default tseslint.config( '**/instrumented/**', '**/coverage/**', 'nyc-config.cjs', - '.lintstagedrc.js', + '.lintstagedrc.mjs', 'cypress.config.js', ] }, diff --git a/package.json b/package.json index f8db399bd..a4fed7836 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,5 @@ { "name": "oodikone", - "type": "module", "description": "An application for analyzing university data.", "scripts": { "cypress": "cypress",