---
title: "Comment by Masoud Salehi on \"Use package.json wisely\" | Hashnode"
description: "About the last part of this article, I&#39;m pretty sure that no one can use this package without installing react , thus it&#39;s not &quot;optional&quot; and"
url: "https://hashnode.com/posts/use-packagejson-wisely/626d6aaba2d355d4df43f1ae/comment/626faba3fa2b07f7d96a7fd2"
---

[Discussion](https://hashnode.com/posts/use-packagejson-wisely/626d6aaba2d355d4df43f1ae)

Comment [Use package.json wisely](https://hashnode.com/posts/use-packagejson-wisely/626d6aaba2d355d4df43f1ae)

[Masoud Salehi](https://hashnode.com/@masoudmsk)

[May 2, 2022](https://hashnode.com/posts/use-packagejson-wisely/626d6aaba2d355d4df43f1ae/comment/626faba3fa2b07f7d96a7fd2)

About the last part of this article, I'm pretty sure that no one can use this package without installing `react`, thus it's not "optional" and must not be marked as so.

For example, you could do that if your package would work with both `react` and `preact`. In this case neither of them are necessary and the developer might have installed only one of them and shouldn't see any warning.

[Amir Hossein Ebrahimi](https://hashnode.com/@amirhe)

[May 2, 2022](https://hashnode.com/posts/use-packagejson-wisely/626d6aaba2d355d4df43f1ae/comment/626faba3fa2b07f7d96a7fd2#reply-626fbfc477f8e2f7fe934ae9)

Haha, good point. Actually, the installation procedure is not skipped; npm will install the package in the 'dependencies' section; if you're interested, you can look at 'package-lock.json'.

However, the issue is whether to make a selection at the package level or as an end-developer persona.

IMHO, every non-tightly dependent output dependence should be treated as optional but should make the installation more controlled for end developers.

[Amir Hossein Ebrahimi](https://hashnode.com/@amirhe)

[May 2, 2022](https://hashnode.com/posts/use-packagejson-wisely/626d6aaba2d355d4df43f1ae/comment/626faba3fa2b07f7d96a7fd2#reply-626fbfcb77f8e2f7fe934af0)

Haha, good point. Actually, the installation procedure is not skipped; npm will install the package in the 'dependencies' section; if you're interested, you can look at 'package-lock.json'.

However, the issue is whether to make a selection at the package level or as an end-developer persona.

IMHO, every non-tightly dependent output dependence should be treated as optional but should make the installation more controlled for end developers.
