Skip to content

Commit

Permalink
merge main
Browse files Browse the repository at this point in the history
  • Loading branch information
rkodev committed Sep 4, 2024
2 parents e4fcbf3 + 786ba2a commit 632e384
Show file tree
Hide file tree
Showing 116 changed files with 9,226 additions and 7,504 deletions.
6 changes: 0 additions & 6 deletions .eslintignore

This file was deleted.

46 changes: 0 additions & 46 deletions .eslintrc.js

This file was deleted.

1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ packages/**/*/lib/
packages/**/*.js
packages/**/*.js.map
packages/**/*.d.ts
**/generatedCode/**
86 changes: 86 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
import jsdoc from "eslint-plugin-jsdoc";
import preferArrow from "eslint-plugin-prefer-arrow";
import typescriptEslint from "@typescript-eslint/eslint-plugin";
import header from "@tony.ganchev/eslint-plugin-header";
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 [{
ignores: [
"**/.eslintrc.js",
"**/*.mjs",
"**/*.js",
"**/*.js.map",
"**/*.d.ts",
"**/node_modules/",
"**/dist/",
],
files: ["**/*.ts"],
}, ...compat.extends(
"eslint:recommended",
"plugin:@typescript-eslint/recommended-type-checked",
"plugin:@typescript-eslint/stylistic-type-checked",
"prettier",
"@microsoft/eslint-config-msgraph/core",
), {
plugins: {
jsdoc,
"prefer-arrow": preferArrow,
"@typescript-eslint": typescriptEslint,
header,
},

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

parser: tsParser,
ecmaVersion: 6,
sourceType: "module",

parserOptions: {
project: [
"packages/abstractions/tsconfig.json",
"packages/bundle/tsconfig.json",
"packages/authentication/azure/tsconfig.json",
"packages/authentication/azure/tsconfig.json",
"packages/http/fetch/tsconfig.json",
"packages/serialization/form/tsconfig.json",
"packages/serialization/json/tsconfig.json",
"packages/serialization/multipart/tsconfig.json",
"packages/authentication/azure/tsconfig.json",
"packages/test/tsconfig.json",
],
},
},

rules: {
"@typescript-eslint/class-literal-property-style": ["error", "fields"],
"@typescript-eslint/no-explicit-any": "warn",
"prefer-arrow/prefer-arrow-functions": "warn",
"@typescript-eslint/prefer-nullish-coalescing": "off",

"header/header": [2, "block", [
"*",
" * -------------------------------------------------------------------------------------------",
" * Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT License.",
" * See License in the project root for license information.",
" * -------------------------------------------------------------------------------------------",
" ",
], 1],
},
}];
1 change: 1 addition & 0 deletions lerna.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"packages": [
"packages/test",
"packages/abstractions",
"packages/bundle",
"packages/http/*",
"packages/serialization/*",
"packages/authentication/*"
Expand Down
Loading

0 comments on commit 632e384

Please sign in to comment.