JAVASCRIPT 19
Web Technologies I - Lecture 1 Guest on 21st February 2022 09:27:42 AM
  1. NodeJS can handle the requests simultaneously.
  2. It is asynchronous, so it does not need to wait for the response.
  3. NodeJS is not used for CPU intensive tasks, but for IO intensive tasks.
  4. Python is usually used for CPU intensive tasks.
  5.  
  6. Installing Visual Studio Code
  7. NVM for Windows
  8.  
  9.  
  10. function msg(){
  11. console.log("This is a tradtional function')
  12. }
  13.  
  14. (function(){
  15. console.log("This is an anonymous function')
  16. })()
  17.  
  18. //Arrow functions
  19. msg = ()=> {console.log("This is an arrow function')}
  20. msg()
  21.  
  22. // Loading the module, displaying the file from txt - This is a blocking code- synchronous
  23. const fs = require('fs');
  24. var data = fs.readFileSync('display.txt', 'utf-8');
  25. console.log(data)
  26.  
  27. // Non-blocking code asynchronous
  28. const fs = require('fs');
  29. var data = fs.readFile('display.txt', 'utf-8', (err, data)=>{
  30. console.log(data)
  31. });
  32. console.log('Done')
  33.  
  34. git init - to create the empty repository
  35. git commit
  36. git add
  37. git status
  38. git branch
  39.  
  40. git checkout Lecture-1
  41. git remote add Lecture-1
  42. git push -u Lecture-1 main

Coding Base is for source code and general debugging text.

Login or Register to edit, delete and keep track of your pastes and more.

Raw Paste

Login or Register to edit or fork this paste. It's free.