Skip to content

Commit

Permalink
chore: update configs
Browse files Browse the repository at this point in the history
  • Loading branch information
Fedorrychkov committed Jul 27, 2024
1 parent 3335529 commit 0e3f830
Show file tree
Hide file tree
Showing 7 changed files with 74 additions and 14 deletions.
11 changes: 11 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Firebase
FIREBASE_API_KEY=

# Поля из сервисного файла firebase, продублировал сюда для использования энвов
FIREBASE_PROJECT_ID=firebase-name
FIREBASE_PRIVATE_KEY=firebase_private_key_from_servicejson
FIREBASE_CLIENT_EMAIL=firebase_client_email_from_servicejson

SA_KEY=path_to_service_file

MINI_APP_URL=domain_to_mini_app
19 changes: 17 additions & 2 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ module.exports = {
tsconfigRootDir: __dirname,
sourceType: 'module',
},
plugins: ['@typescript-eslint/eslint-plugin'],
plugins: ['@typescript-eslint/eslint-plugin', 'simple-import-sort'],
extends: [
'plugin:@typescript-eslint/recommended',
'plugin:prettier/recommended',
Expand All @@ -15,11 +15,26 @@ module.exports = {
node: true,
jest: true,
},
ignorePatterns: ['.eslintrc.js'],
ignorePatterns: ['.eslintrc.js', '/dist/**/*'],
rules: {
'@typescript-eslint/interface-name-prefix': 'off',
'@typescript-eslint/explicit-function-return-type': 'off',
'@typescript-eslint/explicit-module-boundary-types': 'off',
'@typescript-eslint/no-explicit-any': 'off',
quotes: ['error', 'single'],
'import/no-unresolved': 0,
semi: ['error', 'never'],
'object-curly-spacing': ['error', 'always'],
'no-unused-vars': 'off',
'@typescript-eslint/no-unused-vars': 'error',
'require-jsdoc': 0,
'padding-line-between-statements': [
'error',
{ blankLine: "always", prev: "*", next: "return" },
{ blankLine: "always", prev: "*", next: "if" },
{ blankLine: "always", prev: "*", next: "try" },
],
'simple-import-sort/imports': 'error',
'simple-import-sort/exports': 'error',
},
};
20 changes: 13 additions & 7 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,6 @@ lerna-debug.log*
!.vscode/launch.json
!.vscode/extensions.json

# dotenv environment variable files
.env
.env.development.local
.env.test.local
.env.production.local
.env.local

# temp directory
.temp
.tmp
Expand All @@ -54,3 +47,16 @@ pids

# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

# all env files except example
.env*
!.env.example

# google service account file (by firebase)
service-account*.json

# firebase config file
.firebaserc

# tg library local cache file
sessions.json
7 changes: 5 additions & 2 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
{
"semi": false,
"trailingComma": "all",
"singleQuote": true,
"trailingComma": "all"
}
"printWidth": 120,
"tabWidth": 2
}
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"start:dev": "nest start --watch",
"start:debug": "nest start --debug --watch",
"start:prod": "node dist/main",
"lint": "eslint \"{src,apps,libs,test}/**/*.ts\" --fix",
"lint": "eslint \"{src,apps,libs,test}/**/*.ts\"",
"lint:fix": "eslint \"{src,apps,libs,test}/**/*.ts\" --fix",
"test": "jest",
"test:watch": "jest --watch",
"test:cov": "jest --coverage",
Expand All @@ -39,6 +40,7 @@
"eslint": "^8.42.0",
"eslint-config-prettier": "^9.0.0",
"eslint-plugin-prettier": "^5.0.0",
"eslint-plugin-simple-import-sort": "^12.1.1",
"jest": "^29.5.0",
"prettier": "^3.0.0",
"source-map-support": "^0.5.21",
Expand Down
12 changes: 12 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 13 additions & 2 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,17 @@
"noImplicitAny": false,
"strictBindCallApply": false,
"forceConsistentCasingInFileNames": false,
"noFallthroughCasesInSwitch": false
}
"noFallthroughCasesInSwitch": false,
"paths": {
"src/*": [
"src/*"
]
}
},
"compileOnSave": true,
"include": [
"src",
"test",
],
"exclude": ["node_modules"]
}

0 comments on commit 0e3f830

Please sign in to comment.