<div dir="ltr">Hello, i'm all right patching typescript, but that would mean local installs of typescript<div>wouldn't find the modules anyway.</div><div>So... do you know if a local user install of typescript is going to want to discover global modules ?</div><div>If not, then it's okay to patch typescript and i think i can do it...</div><div><br></div><div>Jérémy</div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Le mer. 5 mai 2021 à 09:50, Yadd <<a href="mailto:yadd@debian.org">yadd@debian.org</a>> a écrit :<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi all,<br>
<br>
as you probably already know, Typescript has a poor module search<br>
support. That's why pkg-js-tools supports<br>
debian/nodejs/ext{copies,links}.<br>
<br>
Symlinks (debian/nodejs/extlinks) would be the better solution, but when<br>
a linked module has to include another, Typescript can't find it because<br>
it recursively search for a node_modules directory, starting in<br>
/usr/share/nodejs/<module>. Then each module that requires another has<br>
to be copied (debian/nodejs/extcopies), and recursively all dependencies<br>
(example:<br>
<a href="https://salsa.debian.org/js-team/node-jest/-/blob/master/debian/nodejs/extcopies" rel="noreferrer" target="_blank">https://salsa.debian.org/js-team/node-jest/-/blob/master/debian/nodejs/extcopies</a>).<br>
<br>
I tried to patch Typescript without success.<br>
<br>
We could simplify this by creating "node_modules => nodejs" symlinks in<br>
/usr/share, /usr/lib, /usr/lib/arch. Then no need to copy modules, only<br>
few of them should be declared in debian/nodejs/extlinks.<br>
<br>
Is it an acceptable solution ? Where to store these symlinks, nodejs or<br>
typescript ?<br>
<br>
Cheers,<br>
Yadd<br>
<br>
-- <br>
Pkg-javascript-devel mailing list<br>
<a href="mailto:Pkg-javascript-devel@alioth-lists.debian.net" target="_blank">Pkg-javascript-devel@alioth-lists.debian.net</a><br>
<a href="https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/pkg-javascript-devel" rel="noreferrer" target="_blank">https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/pkg-javascript-devel</a><br>
</blockquote></div>