1 |
On Mon, Jul 4, 2016 at 1:20 AM, Nicolas Bock <nicolasbock@g.o> wrote: |
2 |
> On 07/04/2016 10:15 AM, Daniel Campbell wrote: |
3 |
>> On 07/04/2016 12:57 AM, Nicolas Bock wrote: |
4 |
>>> Hi, |
5 |
>>> |
6 |
>>> I would like to package a code that depends on JavaScript packages. The |
7 |
>>> suggested installation procedure from upstream involves running `npm |
8 |
>>> install ...`. How do we (or do we?) deal with JavaScript packages? |
9 |
>>> |
10 |
>>> Best, |
11 |
>>> |
12 |
>>> Nick |
13 |
>>> |
14 |
>> The better question to ask is "what does this program need in order to |
15 |
>> function?" If it installed through 'npm', that's going to point to Node. |
16 |
>> Whatever format Node uses for its packages, you should read it and find |
17 |
>> out if it requires anything else besides Node. If other Node packages |
18 |
>> are needed, they may be in the tree already. |
19 |
>> |
20 |
> The program runs without JS. However, it can also run a server that |
21 |
> provides a UI through a browser. That's the part that requires the JS. |
22 |
> |
23 |
|
24 |
I've seen some packages provide a "pre-built" javascript bundle, which |
25 |
is great because then you don't need a bunch of nodejs modules just to |
26 |
minify some javascript and whatnot. |
27 |
|
28 |
Alternatively, you could have a pre-made tarball of nodejs modules |
29 |
that's downloaded via SRC_URI and used only at build time. |