Sunday, February 19, 2023

Dependency Injection 2

What is Dependency Injection

  • Produce a loosely coupled code
  • Any change in the class without affecting other object.
  • Type of DI
    • Constructor Injection
      • parameter to inject dependencies in a class
      • One parameterized constructor but no default constructor and you need to pass specified values to the constructor


    • Setter Injection
      • through properties of a class


    • Interface-based injection
      • through method


  • Advantage
    • Maintainability
      • maintain code structure, single principle
    • Flexibility
      • loosely coupled code, flexible to use different ways.
    • Testability
      • easy to do unit testing
    • Readability
      • Logic in constructor.













Friday, August 19, 2022

Back to previous commit

 # Resets index to former commit; replace '56e05fced' with your commit code

git reset 56e05fced 

# Moves pointer back to previous HEAD
git reset --soft HEAD@{1}

git commit -m "Revert to 56e05fced"

# Updates working copy to reflect the new commit
git reset --hard

Monday, June 20, 2022

bootstrap footer always bottom

<div class="d-flex flex-column min-vh-100">
<footer class="mt-auto earth">
</footer>
</div>

Thursday, June 9, 2022

Git Change Repo

both are Same (Set new origin)

git remote set-url origin https://github.com/123123.git

git branch -M main

git push -u origin main

-----------------


git remote rm origin

git remote add origin https://github.com/123123.git

git branch -M main

git push -u origin main


------------------


after git push

git tag v1.0.1

git checkout v1.0.1


firebase login:use <email>



Tuesday, May 31, 2022

Change Firebase Project

  1.  firebasesrc change to correct firebase project
  2. Enable Firestore (set region asiasoutheast1)
  3. Try to Deploy First (must blaze project)

firebase login:add
firebase login:list
firebase login:use


change another login and deploy

Wednesday, May 25, 2022

Git Replace without MR


 https://www.nickang.com/2017-09-30-replace-git-branch-code/

Monday, September 20, 2021

POSTMAN Running

Running and store the result to Environment



  • Runner to Run CSV file 
  • In the collection, click "Run Button"

  • This how you put the Body mapping to csv file.
  • Careful the ""
  • Import the CSV and run.
  • can be json file too
x