- Instalar TypeScript y demás dependencias
npm i -D typescript @types/node ts-node-dev rimraf
- Inicializar el archivo de configuración de TypeScript ( Se puede configurar al gusto)
npx tsc --init --outDir dist/ --rootDir src
openssl req -x509 -sha256 -nodes -days 365 -newkey rsa:2048 -keyout server.key -out server.crt | |
Documentación oficial sobre Jest
npm install -D jest @types/jest ts-jest supertest
Más información - Docs Oficiales
npm i -D typescript @types/node
Table users { | |
user_id integer [pk, increment] | |
username varchar [not null, unique] | |
email varchar [not null, unique] | |
password varchar [not null] | |
name varchar [not null] | |
role varchar [not null] | |
gender varchar(10) [not null] |
Información extraída de HolisticsBlog
@IsString() | |
@MinLength(6) | |
@MaxLength(50) | |
@Matches( | |
/(?:(?=.*\d)|(?=.*\W+))(?![.\n])(?=.*[A-Z])(?=.*[a-z]).*$/, { | |
message: 'The password must have a Uppercase, lowercase letter and a number' | |
}) | |
password: string; |
import { createSlice } from '@reduxjs/toolkit'; | |
export const templateSlice = createSlice({ | |
name: 'name', | |
initialState: { | |
counter: 10 | |
}, | |
reducers: { | |
increment: (state, /* action */ ) => { | |
//! https://react-redux.js.org/tutorials/quick-start |