Skip to content

Commit

Permalink
Merge pull request #1609 from skaut/frontend-module
Browse files Browse the repository at this point in the history
Switched frontend to type: module
  • Loading branch information
marekdedic authored Sep 5, 2024
2 parents 66f7485 + 0edceba commit 009202a
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 17 deletions.
25 changes: 12 additions & 13 deletions packages/frontend/eslint.config.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
const js = require("@eslint/js");
const eslintComments = require("@eslint-community/eslint-plugin-eslint-comments");
const commentsConfig = require("@eslint-community/eslint-plugin-eslint-comments/configs");
const compat = require("eslint-plugin-compat");
const jest = require("eslint-plugin-jest");
const perfectionist = require("eslint-plugin-perfectionist");
const preferArrowFunctions = require("eslint-plugin-prefer-arrow-functions");
const prettierRecommended = require("eslint-plugin-prettier/recommended");
const react = require("eslint-plugin-react");
const globals = require("globals");
const tseslint = require("typescript-eslint");
import js from "@eslint/js";
import eslintComments from "@eslint-community/eslint-plugin-eslint-comments";
import commentsConfig from "@eslint-community/eslint-plugin-eslint-comments/configs";
import compat from "eslint-plugin-compat";
import jest from "eslint-plugin-jest";
import perfectionist from "eslint-plugin-perfectionist";
import preferArrowFunctions from "eslint-plugin-prefer-arrow-functions";
import prettierRecommended from "eslint-plugin-prettier/recommended";
import react from "eslint-plugin-react";
import globals from "globals";
import tseslint from "typescript-eslint";

/* eslint-disable @typescript-eslint/naming-convention -- Not applicable to this file */

module.exports = tseslint.config(
export default tseslint.config(
js.configs.recommended,
prettierRecommended,
commentsConfig.recommended,
Expand Down Expand Up @@ -284,7 +284,6 @@ module.exports = tseslint.config(
files: ["**/*.js"],
rules: {
"@typescript-eslint/explicit-function-return-type": "off",
"@typescript-eslint/no-require-imports": "off",
"@typescript-eslint/no-unsafe-argument": "off",
"@typescript-eslint/no-unsafe-assignment": "off",
"@typescript-eslint/no-unsafe-member-access": "off",
Expand Down
2 changes: 1 addition & 1 deletion packages/frontend/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/** @type {import('jest').Config} */
module.exports = {
export default {
collectCoverage: true,
collectCoverageFrom: [
"src/**/*.{ts,tsx}",
Expand Down
1 change: 1 addition & 0 deletions packages/frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
"type": "git",
"url": "git+https://github.com/skaut/poptavky.git"
},
"type": "module",
"scripts": {
"clean": "rimraf dist/*",
"prebuild": "npm run clean",
Expand Down
6 changes: 3 additions & 3 deletions packages/frontend/vite.config.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const legacy = require("@vitejs/plugin-legacy");
const react = require("@vitejs/plugin-react");
const { defineConfig } = require("vite");
import legacy from "@vitejs/plugin-legacy";
import react from "@vitejs/plugin-react";
import { defineConfig } from "vite";

export default defineConfig({
build: {
Expand Down

0 comments on commit 009202a

Please sign in to comment.