adding npm workspaces (#12)

This commit was merged in pull request #12.
This commit is contained in:
2024-05-21 18:19:37 -05:00
committed by GitHub
parent 4fc0401ddf
commit 3b68021d93
14 changed files with 14109 additions and 37 deletions

View File

@@ -3,23 +3,20 @@ module.exports = {
parserOptions: {
project: 'tsconfig.json',
tsconfigRootDir: __dirname,
sourceType: 'module',
sourceType: 'module'
},
plugins: ['@typescript-eslint/eslint-plugin'],
extends: [
'plugin:@typescript-eslint/recommended',
'plugin:prettier/recommended',
],
extends: ['plugin:@typescript-eslint/recommended', 'prettier'],
root: true,
env: {
node: true,
jest: true,
jest: true
},
ignorePatterns: ['.eslintrc.js'],
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',
},
'@typescript-eslint/no-explicit-any': 'off'
}
};

View File

@@ -1,4 +0,0 @@
{
"singleQuote": true,
"trailingComma": "all"
}

View File

@@ -7,7 +7,6 @@
"license": "UNLICENSED",
"scripts": {
"build": "nest build",
"format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"",
"start": "nest start",
"start:dev": "nest start --watch",
"start:debug": "nest start --debug --watch",
@@ -40,13 +39,7 @@
"@types/jest": "^29.5.2",
"@types/node": "^20.3.1",
"@types/supertest": "^6.0.0",
"@typescript-eslint/eslint-plugin": "^6.0.0",
"@typescript-eslint/parser": "^6.0.0",
"eslint": "^8.42.0",
"eslint-config-prettier": "^9.0.0",
"eslint-plugin-prettier": "^5.0.0",
"jest": "^29.5.0",
"prettier": "^3.0.0",
"source-map-support": "^0.5.21",
"supertest": "^6.3.3",
"ts-jest": "^29.1.0",

View File

@@ -8,7 +8,7 @@ describe('AppController', () => {
beforeEach(async () => {
const app: TestingModule = await Test.createTestingModule({
controllers: [AppController],
providers: [AppService],
providers: [AppService]
}).compile();
appController = app.get<AppController>(AppController);

View File

@@ -5,6 +5,6 @@ import { AppService } from './app.service';
@Module({
imports: [],
controllers: [AppController],
providers: [AppService],
providers: [AppService]
})
export class AppModule {}

View File

@@ -5,7 +5,7 @@ import { AppModule } from './app.module';
export async function createApp(): Promise<INestApplication> {
const app = await NestFactory.create(AppModule);
app.setGlobalPrefix('api');
await app.init();
return app;
}

View File

@@ -8,7 +8,7 @@ describe('AppController (e2e)', () => {
beforeEach(async () => {
const moduleFixture: TestingModule = await Test.createTestingModule({
imports: [AppModule],
imports: [AppModule]
}).compile();
app = moduleFixture.createNestApplication();