ryann
ryann3w ago

`deno add -D`

What is the -D flag doing in deno? I mean according to the manual: -D, --dev Add as a dev dependency But is anything imported differently in deno.json? To me it looks like it's the same
5 Replies
crowlKats
crowlKats3w ago
this is only applicable for package.json
ryann
ryannOP3w ago
So how does deno decide which packages to include when building? It only includes the imported libraries? In other words, if I install a library and don't import it, will it be like "devDependencies" in package.json?
crowlKats
crowlKats3w ago
what do you mean with "building"?
ryann
ryannOP3w ago
I guess when compiling, or publishing npm does not include devDependencies when you publish or compile the code
crowlKats
crowlKats3w ago
when deno runs, it only uses the dependencies it needs. same applies for jsr