File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed
Roadmap/20 - PETICIONES HTTP/typescript Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -154,20 +154,18 @@ class PokemonService {
154
154
}
155
155
156
156
function menu ( ) {
157
- process . stdout . write (
158
- "Ingrese el nombre o id del pokémon (o 'salir' para terminar): "
159
- ) ;
157
+ console . log ( "Ingrese el nombre o id del pokémon (o 'salir' para terminar): " ) ;
160
158
161
159
process . stdin . on ( "data" , async ( data : string ) => {
162
160
const input = data . toString ( ) . trim ( ) . toLowerCase ( ) ;
163
161
164
162
if ( input === "salir" ) {
165
- process . stdout . write ( "Saliendo del programa...\n" ) ;
163
+ console . log ( "Saliendo del programa...\n" ) ;
166
164
process . stdin . close ( ) ;
167
165
} else {
168
166
const information = await PokemonService . searchInformation ( input ) ;
169
167
console . log ( information ) ;
170
- process . stdout . write (
168
+ console . log (
171
169
"Ingrese el nombre o id del pokémon (o 'salir' para terminar): "
172
170
) ;
173
171
}
You can’t perform that action at this time.
0 commit comments