Skip to content

Instantly share code, notes, and snippets.

View SebastianCB-dev's full-sized avatar
💙
Chelsea F.C.

SebastianCB SebastianCB-dev

💙
Chelsea F.C.
View GitHub Profile
# How to use Angular with SASS
1. Create Angular project with SCSS
2. Execute "npm i -g sass"
3. Go to angular.json and in the configurations-development add the next line:
"inlineStyleLanguage": "scss"
@SebastianCB-dev
SebastianCB-dev / instalacionesCapacitacion2022.md
Last active March 21, 2022 16:02
Instalaciones recomendadas para la capacitación de desarrollo web 2022

Instalaciones recomendadas Desarrollo Web 2022

Todas las instalaciones acá serán gratuitas.

Visual Studio Code

  • Visual Studio Code es nuestro editor de codigo que nos ayudará a escribir codigo de manera mas rapida y sencilla.

Click para descargar VSCode

Git

@SebastianCB-dev
SebastianCB-dev / iris_data.csv
Last active June 9, 2022 13:42
Iris flower Dataset
sepal_length sepal_width petal_length petal_width class
5.1 3.5 1.4 0.2 0
4.9 3.0 1.4 0.2 0
4.7 3.2 1.3 0.2 0
4.6 3.1 1.5 0.2 0
5.0 3.6 1.4 0.2 0
5.4 3.9 1.7 0.4 0
4.6 3.4 1.4 0.3 0
5.0 3.4 1.5 0.2 0
4.4 2.9 1.4 0.2 0
@SebastianCB-dev
SebastianCB-dev / Connection between Python and PostgreSQL
Created July 14, 2022 19:31
This is a script to connect PostgreSQL with Python3
import psycopg2 as pg
conn = pg.connect(user="postgres",
password="root",
host="localhost",
port="5432",
database="python_postgres")
try:
with conn as cn:
@SebastianCB-dev
SebastianCB-dev / parse-jwt.js
Created December 7, 2022 15:29 — forked from Klerith/parse-jwt.js
Parse - JWT - Obtener Payload y fecha de creación y expiración
function parseJwt (token) {
var base64Url = token.split('.')[1];
var base64 = base64Url.replace('-', '+').replace('_', '/');
return JSON.parse(window.atob(base64));
};
@SebastianCB-dev
SebastianCB-dev / angular-jest-installation.md
Created January 28, 2023 15:47 — forked from Klerith/angular-jest-installation.md
Angular 13+ Configure Jest Testing

Angular testing con JEST

  1. Remover cualquier referencia de Jasmine / Karma en el package.json
npm remove <karma karma-chrome-launcher...>
  1. Instalar Jest
npm install --save-dev jest jest-preset-angular @types/jest
@SebastianCB-dev
SebastianCB-dev / index.html
Created March 7, 2023 18:45
React Cascaron HTML
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>ReactApp</title>
<!-- Cargar React -->
<script crossorigin
src="https://unpkg.com/react@16/umd/react.production.min.js">
@SebastianCB-dev
SebastianCB-dev / nginx.conf
Last active March 9, 2023 21:23
nginx Configuration
server {
listen 80;
sendfile on;
default_type application/octet-stream;
gzip on;
gzip_http_version 1.1;
gzip_disable "MSIE [1-6]\.";
gzip_min_length 256;
gzip_vary on;
@SebastianCB-dev
SebastianCB-dev / configurar-node-ts.md
Created September 15, 2023 21:06 — forked from Klerith/configurar-node-ts.md
Node con TypeScript - TS-Node-dev simplificado

Node con TypeScript - TS-Node-dev (preferido)

  1. Instalar TypeScript y demás dependencias
npm i -D typescript @types/node ts-node-dev rimraf
  1. Inicializar el archivo de configuración de TypeScript ( Se puede configurar al gusto)
npx tsc --init --outDir dist/ --rootDir src
@SebastianCB-dev
SebastianCB-dev / vite-testing-config.md
Created September 27, 2023 23:31 — forked from Klerith/vite-testing-config.md
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: