Skip to content

Instantly share code, notes, and snippets.

View pablotolentino's full-sized avatar
🏠
Working from home

Pablo Tolentino pablotolentino

🏠
Working from home
View GitHub Profile
@pablotolentino
pablotolentino / Key_starUML.md
Created July 14, 2024 17:45 — forked from danielquisbert/Key_starUML.md
Key para starUML
public static convertirAEntero(texto): number {
if (texto === null) {
return 0;
}
if (texto.length == 0) {
return 0;
}
public static convertirAEntero(texto): number {
if (texto !== null) {
if (texto.length > 0) {
if (!isNaN(texto)) {
return parseInt(texto);
} else {
return 0;
}
} else {
try {
abrirArchivo(archivo);
leerArchivo(archivo)
} catch (err) {
console.error(err.message);
} finally {
cerrarArchivo(archivo);
}
try {
throw new Error('el error');
} catch (err) {
console.error(err.message);
} finally {
console.error('finally');
}
// Resultado:
// el error
// finally
try {
throw new Error('mi error');
} finally {
console.error('finally');
}
// resultado: finally
try {
throw new Error('esto es un error');
} catch (err) {
console.error(err.message);
}
// resultado: esto es un error
import { Component } from '@angular/core';
@Component({
selector: 'fb-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css']
})
export class AppComponent {
title = 'facebook';
}
import { Component } from '@angular/core';
@Component({
selector: 'app-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css']
})
export class AppComponent {
title = 'google';
}
{
"name": "google",
"version": "0.0.0",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"