-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refatora tipos de usuário e aplica rate limiting nas rotas de autenti…
…cação e snippets
- Loading branch information
Showing
10 changed files
with
145 additions
and
141 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
import app from './app'; | ||
import env from './config/env'; | ||
import './types/'; | ||
|
||
const PORT = env.PORT || ''; | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import { Request } from 'express'; | ||
|
||
declare module 'express-serve-static-core' { | ||
interface Request { | ||
user?: { | ||
id: string; | ||
name?: string; | ||
email?: string; | ||
}; | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,18 @@ | ||
{ | ||
"compilerOptions": { | ||
/* Language and Environment */ | ||
"target": "ES2020", // Define a versão ECMAScript para o código gerado. | ||
"module": "commonjs", // Sistema de módulos padrão para Node.js. | ||
"lib": ["ES2020"], // Inclui declarações para ES2020. | ||
"esModuleInterop": true, // Permite importação de módulos ES6 como CommonJS. | ||
"forceConsistentCasingInFileNames": true, // Garante consistência de capitalização em nomes de arquivos. | ||
|
||
/* Modules */ | ||
"moduleResolution": "node", // Resolve módulos como o Node.js. | ||
"resolveJsonModule": true, // Permite a importação de módulos JSON. | ||
|
||
/* Typo Roots */ | ||
"typeRoots": ["./node_modules/@types", "./src/types"], // Caminho para as definições de tipo. | ||
|
||
/* Emit */ | ||
"outDir": "./dist", // Define o diretório de saída para arquivos compilados. | ||
"rootDir": "./src", // Define o diretório raiz para os arquivos TypeScript. | ||
"types": ["jest"], // Inclui tipos de teste do Jest. | ||
"sourceMap": true, // Gera arquivos de mapa de origem para depuração. | ||
|
||
/* Type Checking */ | ||
"strict": true, // Habilita todas as verificações de tipo estritas. | ||
"skipLibCheck": true // Ignora a verificação de tipo em arquivos de declaração (.d.ts). | ||
"target": "ES2020", | ||
"module": "commonjs", | ||
"lib": ["ES2020"], | ||
"strict": true, | ||
"esModuleInterop": true, | ||
"forceConsistentCasingInFileNames": true, | ||
"moduleResolution": "node", | ||
"typeRoots": ["./node_modules/@types", "./src/types"], // Certifique-se disso! | ||
"resolveJsonModule": true, | ||
"outDir": "./dist", | ||
"rootDir": "./src", | ||
"skipLibCheck": true | ||
}, | ||
"include": ["src/**/*"], // Inclui apenas a pasta 'src' para compilação. | ||
"exclude": ["node_modules", "dist"] // Exclui 'node_modules' e 'dist' da compilação. | ||
"include": ["src/**/*"], | ||
"exclude": ["node_modules", "dist"] | ||
} |