pFad - Phone/Frame/Anonymizer/Declutterfier! Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

URL: http://github.com/Ifycode-study/nestjs-computer-DI

igin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/primer-0fcd9af82350aeda.css" /> GitHub - Ifycode-study/nestjs-computer-DI: Associated with @catlog-shop · GitHub
Skip to content

Ifycode-study/nestjs-computer-DI

Repository files navigation

Nestjs computer DI api

Course: "NestJS: The Complete Developer's Guide" by Stephen Grider.

App goal: Quick project to understand modules and Dependency Injection (DI). Also includes how to share services between different modules.

Command for generating modules:

nest g module module-name-here

Command for generating services (with service test files):

nest g service service-name-here

Command for generating controller (with controller test files):

nest g controller controller-name-here

Diagram showing connection between all 4 modules

conneection between api moodules

Setting up Dependency Injection between modules

  • The first module: Add the service to the module's list of exports.
  • Import the above first module into the new module (i.e. add it to the import list of the new module).
  • Define the constructor method in the service of the new module and add (inject) the first module's service into it.

About

Associated with @catlog-shop

Resources

Stars

Watchers

Forks

Contributors

pFad - Phonifier reborn

Pfad - The Proxy pFad © 2024 Your Company Name. All rights reserved.





Check this box to remove all script contents from the fetched content.



Check this box to remove all images from the fetched content.


Check this box to remove all CSS styles from the fetched content.


Check this box to keep images inefficiently compressed and original size.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy