feat: 更新了依赖版本
This commit is contained in:
parent
1edb04e024
commit
4b995fbd8b
|
|
@ -0,0 +1,2 @@
|
||||||
|
node_modules
|
||||||
|
dist
|
||||||
29
.eslintrc.js
29
.eslintrc.js
|
|
@ -1,27 +1,24 @@
|
||||||
module.exports = {
|
module.exports = {
|
||||||
env: {
|
env: { browser: true, commonjs: true, es2022: true },
|
||||||
browser: true,
|
extends: [
|
||||||
commonjs: true,
|
'eslint:recommended',
|
||||||
es2022: true,
|
'plugin:@typescript-eslint/eslint-recommended',
|
||||||
},
|
'plugin:@typescript-eslint/recommended',
|
||||||
extends: ['standard-with-typescript', 'prettier'],
|
'prettier',
|
||||||
plugins: ['prettier'],
|
],
|
||||||
|
plugins: ['@typescript-eslint', 'prettier'],
|
||||||
overrides: [
|
overrides: [
|
||||||
{
|
{
|
||||||
env: {
|
env: { node: true },
|
||||||
node: true,
|
|
||||||
},
|
|
||||||
files: ['.eslintrc.{js,cjs}'],
|
files: ['.eslintrc.{js,cjs}'],
|
||||||
parserOptions: {
|
parserOptions: { sourceType: 'script' },
|
||||||
sourceType: 'script',
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
parser: '@typescript-eslint/parser',
|
||||||
parserOptions: {
|
parserOptions: {
|
||||||
ecmaVersion: 'latest',
|
ecmaVersion: 'latest',
|
||||||
project: './tsconfig.json',
|
project: './tsconfig.json',
|
||||||
|
sourceType: 'module',
|
||||||
},
|
},
|
||||||
rules: {
|
rules: { 'prettier/prettier': 'error' },
|
||||||
'prettier/prettier': 'error',
|
|
||||||
},
|
|
||||||
};
|
};
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load Diff
27
package.json
27
package.json
|
|
@ -16,20 +16,19 @@
|
||||||
"author": "",
|
"author": "",
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@commitlint/cli": "^17.7.1",
|
"@commitlint/cli": "^19.8.0",
|
||||||
"@commitlint/config-conventional": "^17.7.0",
|
"@commitlint/config-conventional": "^19.8.0",
|
||||||
"@typescript-eslint/eslint-plugin": "^6.4.1",
|
"@typescript-eslint/eslint-plugin": "^8.27.0",
|
||||||
"eslint": "^8.47.0",
|
"eslint": "^8.27.0",
|
||||||
"eslint-config-prettier": "^9.0.0",
|
"eslint-config-prettier": "^10.1.1",
|
||||||
"eslint-config-standard-with-typescript": "^38.0.0",
|
"eslint-plugin-import": "^2.31.0",
|
||||||
"eslint-plugin-import": "^2.28.1",
|
"eslint-plugin-n": "^17.16.2",
|
||||||
"eslint-plugin-n": "^16.0.2",
|
"eslint-plugin-prettier": "^5.2.3",
|
||||||
"eslint-plugin-prettier": "^5.0.0",
|
"eslint-plugin-promise": "^7.2.1",
|
||||||
"eslint-plugin-promise": "^6.1.1",
|
"husky": "^9.1.7",
|
||||||
"husky": "^8.0.3",
|
"prettier": "^3.5.3",
|
||||||
"prettier": "^3.0.2",
|
"ts-node": "^10.9.2",
|
||||||
"ts-node": "^10.9.1",
|
"typescript": "5.8.2"
|
||||||
"typescript": "5.1.6"
|
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"tsconfig-paths": "^4.2.0"
|
"tsconfig-paths": "^4.2.0"
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,4 @@
|
||||||
|
|
||||||
const isPrime = (n: number): boolean => {
|
const isPrime = (n: number): boolean => {
|
||||||
if (n <= 1 || !Number.isInteger(n)) {
|
if (n <= 1 || !Number.isInteger(n)) {
|
||||||
throw new Error('输入必须是大于1的整数');
|
throw new Error('输入必须是大于1的整数');
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue