Skip to content

Commit

Permalink
chore: migrate to @adonisjs/tooling-config
Browse files Browse the repository at this point in the history
  • Loading branch information
Julien-R44 committed Jul 3, 2023
1 parent 22a9e23 commit eceabce
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 65 deletions.
42 changes: 8 additions & 34 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@
"version": "npm run build",
"prepublishOnly": "npm run build",
"lint": "eslint . --ext=.ts",
"typecheck": "tsc --noEmit",
"format": "prettier --write .",
"sync-labels": "github-label-sync --labels .github/labels.json adonisjs/core",
"quick:test": "node --loader=ts-node/esm --enable-source-maps --experimental-import-meta-resolve bin/test.ts",
Expand All @@ -113,6 +114,9 @@
"license": "MIT",
"devDependencies": {
"@adonisjs/assembler": "^6.1.3-6",
"@adonisjs/eslint-config": "^1.1.7",
"@adonisjs/prettier-config": "^1.1.7",
"@adonisjs/tsconfig": "^1.1.7",
"@commitlint/cli": "^17.6.1",
"@commitlint/config-conventional": "^17.6.1",
"@japa/assert": "2.0.0-1",
Expand All @@ -130,9 +134,6 @@
"cross-env": "^7.0.3",
"del-cli": "^5.0.0",
"eslint": "^8.38.0",
"eslint-config-prettier": "^8.8.0",
"eslint-plugin-adonis": "^3.0.3",
"eslint-plugin-prettier": "^4.2.1",
"get-port": "^6.1.2",
"github-label-sync": "^2.3.1",
"husky": "^8.0.3",
Expand Down Expand Up @@ -194,42 +195,15 @@
"url": "https://github.com/adonisjs/core/issues"
},
"homepage": "https://github.com/adonisjs/core#readme",
"eslintConfig": {
"extends": [
"plugin:adonis/typescriptPackage",
"prettier"
],
"plugins": [
"prettier"
],
"rules": {
"prettier/prettier": [
"error",
{
"endOfLine": "auto"
}
]
}
},
"eslintIgnore": [
"build",
"backup"
],
"prettier": {
"trailingComma": "es5",
"semi": false,
"singleQuote": true,
"useTabs": false,
"quoteProps": "consistent",
"bracketSpacing": true,
"arrowParens": "always",
"printWidth": 100
},
"commitlint": {
"extends": [
"@commitlint/config-conventional"
]
},
"eslintConfig": {
"extends": "@adonisjs/eslint-config/package"
},
"prettier": "@adonisjs/prettier-config",
"publishConfig": {
"access": "public",
"tag": "next"
Expand Down
6 changes: 3 additions & 3 deletions tests/test_utils/http.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ const BASE_URL = new URL('./tmp/', import.meta.url)
test.group('Test utils | Http', () => {
test('start HTTP server using test utils', async ({ assert, cleanup }) => {
const server = createServer()
cleanup(() => server.close())
cleanup(() => { server.close() })

const ignitor = new IgnitorFactory()
.withCoreConfig()
Expand Down Expand Up @@ -51,7 +51,7 @@ test.group('Test utils | Http', () => {

test('close HTTP server using the cleanup function', async ({ assert, cleanup }) => {
const server = createServer()
cleanup(() => server.close())
cleanup(() => { server.close() })

const ignitor = new IgnitorFactory()
.withCoreConfig()
Expand Down Expand Up @@ -160,7 +160,7 @@ test.group('Test utils | Http', () => {

test('raise error when closing an already closed server', async ({ assert, cleanup }) => {
const server = createServer()
cleanup(() => server.close())
cleanup(() => { server.close() })

const ignitor = new IgnitorFactory()
.withCoreConfig()
Expand Down
30 changes: 2 additions & 28 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,33 +1,7 @@
{
"extends": "@adonisjs/tsconfig/tsconfig.package.json",
"compilerOptions": {
"target": "ESNext",
"module": "NodeNext",
"lib": ["ESNext"],
"noUnusedLocals": true,
"noUnusedParameters": true,
"isolatedModules": true,
"removeComments": true,
"declaration": true,
"rootDir": "./",
"outDir": "./build",
"esModuleInterop": true,
"strictNullChecks": true,
"allowSyntheticDefaultImports": true,
"forceConsistentCasingInFileNames": true,
"strictPropertyInitialization": true,
"noImplicitAny": true,
"experimentalDecorators": true,
"emitDecoratorMetadata": true,
"strictBindCallApply": true,
"strictFunctionTypes": true,
"noImplicitThis": true,
"declarationMap": true,
"skipLibCheck": true,
"types": ["@types/node"]
},
"include": ["./**/*"],
"exclude": ["./node_modules", "./build", "./backup"],
"ts-node": {
"swc": true
"outDir": "./build"
}
}

0 comments on commit eceabce

Please sign in to comment.