-1

I have 2 different Angular projects existing in the same workspace.

One with project name as cards and component name is InquiryComponent.

enter image description here

The other project name with cs-leave-inquiry and component name as LeaveInquiryComponent.

enter image description here

Now I want to access the component LeaveInquiryComponent inside InquiryComponent. Is this possible using shared modules?

SiddAjmera
  • 38,129
  • 5
  • 72
  • 110
Nancy
  • 911
  • 7
  • 26
  • 54

1 Answers1

0

Since these are two different projects, you can create a SharedModule and then move the LeaveInquiryComponent in the SharedModule and export it from there. You probably will have to package it as a node_module.

Once you do that, you can then import that SharedModule in both of your projects' modules(In a module that you want to use this in)

SiddAjmera
  • 38,129
  • 5
  • 72
  • 110
  • I have created a module for both the pjts and imported the inquirymodule to the cards pjt. Now I am getting related to the files present in assets folder. since I have translate pipe used for localization, its throwing errors. How to import the assets folder to the pjt. If i place a plain html tag, it works fine. – Nancy Oct 26 '18 at 06:51