You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have three projects - angular app, angular library and a tool that must examine angular classes. This tool uses ts-node and now can work without problems with classes from angular library. However, when I want to examine classes from angular app I have a problem. For example, in angular application I have a module:
import { AbstractFoo } from "@abc/mylib/core"; // this class is from angular library
export class Foo extends AbstractFoo {...}
And this is what I get when I try to process this module with my tool:
/home/pavel/app/node_modules/ts-node/dist-raw/node-internal-modules-esm-resolve.js:352
throw new ERR_MODULE_NOT_FOUND(
^
CustomError: Cannot find module '/home/pavel/app/node_modules/@abc/mylib/core' imported from /home/pavel/app/src/app/foo.ts
at finalizeResolution (/home/pavel/app/node_modules/ts-node/dist-raw/node-internal-modules-esm-resolve.js:352:11)
at moduleResolve (/home/pavel/app/node_modules/ts-node/dist-raw/node-internal-modules-esm-resolve.js:801:10)
At the same time in /home/app/node_modules/@abc/mylib/core I have type files and folders esm2020, fesm2015, fesm2020 with angular compiled code.
Could anyone say how to import a module that uses such compiled angular library?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I have three projects - angular app, angular library and a tool that must examine angular classes. This tool uses ts-node and now can work without problems with classes from angular library. However, when I want to examine classes from angular app I have a problem. For example, in angular application I have a module:
And this is what I get when I try to process this module with my tool:
At the same time in
/home/app/node_modules/@abc/mylib/core
I have type files and foldersesm2020
,fesm2015
,fesm2020
with angular compiled code.Could anyone say how to import a module that uses such compiled angular library?
Beta Was this translation helpful? Give feedback.
All reactions