Skip to content

Instantly share code, notes, and snippets.

View leonidas198's full-sized avatar

leonidas enrique chavez leonidas198

View GitHub Profile
@Klerith
Klerith / vite-testing-config.md
Last active July 22, 2024 19:01
Vite + Jest + React Testing Library - Configuraciones a seguir

Instalación y configuracion de Jest + React Testing Library

En proyectos de React + Vite

  1. Instalaciones:
yarn add --dev jest babel-jest @babel/preset-env @babel/preset-react 
yarn add --dev @testing-library/react @types/jest jest-environment-jsdom
  1. Opcional: Si usamos Fetch API en el proyecto:
@Klerith
Klerith / EventModal.js
Last active July 15, 2024 20:06
Contenido HTML del Modal
<h1> Nuevo evento </h1>
<hr />
<form className="container">
<div className="form-group mb-2">
<label>Fecha y hora inicio</label>
<input className="form-control" placeholder="Fecha inicio" />
</div>
<div className="form-group mb-2">
@Klerith
Klerith / modal.css
Created June 8, 2020 17:40
React Modal Styles
/* Modal */
.ReactModalPortal > div{
opacity: 0;
}
.ReactModalPortal .ReactModal__Overlay {
align-items: center;
display: flex;
justify-content: center;
transition: opacity .2s ease-in-out;
@Klerith
Klerith / calendar-messages-es.js
Last active July 14, 2024 00:16
Big-Calendar - mensajes en español
export const messages = {
allDay: 'Todo el día',
previous: '<',
next: '>',
today: 'Hoy',
month: 'Mes',
week: 'Semana',
day: 'Día',
agenda: 'Agenda',
date: 'Fecha',