Issue on using imported npm package from AWS Code Artifact

0

I have created a npm package in AWS code Artifact. Then I have import it in another project using AWS CLI and with proper AWS Configurations. And I can able to see the imported library in project's package.json and the node_modules folder. Now the problem is when I try to import the library using "import" command, I am facing "Module not found Error" . If anyone have hand on experience in npm package implementation and using packages from AWS CodeArtifact please assist me on in this issue.

1개 답변
0

The recommend methods to use Using CodeArtifact with npm is mentioned in this reference link :

[1] Using CodeArtifact with npm - https://docs.aws.amazon.com/codeartifact/latest/ug/using-npm.html

This error[cannot find module] generally occurs because you’re trying to import an item from a module you don’t have installed in your project directory

To resolve the issue you need to install the package that is absent in your project directory – npm install package-name or yarn add package-name. using the methods mentioned in the above mentioned reference link [1].

AWS
지원 엔지니어
답변함 8달 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인