Why egg.json is not an equivalent to package.json #223
martonlederer
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
When Ryan Dahl introduced Deno, he talked about the things he regrets about Node, and how this new, more advanced runtime fixes these issues.
One of the points he raised was the centralization around the npm package manager and npm's
package.json
configuration file.Deno allows developers to code with true decentralization. It utilizes URL imports, so the need of a package manager is no longer present.
The URL imports also raised many issues, but I'm not going to detail them here, because these issues are the reason why nest.land exists in the first place, we have these listed on our homepage and on our docs.
The reason I'm writing this post is because nest.land receives critique about it's
egg.json
/egg.yaml
very often, that it's the same as Node'spackage.json
and violates one of the most important decisions of Deno.Let's take a look at Node's
package.json
first. It is used for script storing, dependency management, project info, and as a configuration file. It is necessary for a proper Node app, you'll eventually have to use it if you want to create a program or just a package.Nest.land's egg file is different. It is not required for an application that wants to use nest.land modules and it doesn't store scripts nor dependencies. It's only porpoise is to shorten the command that developers use to publish to our registry.
In the future, we are planning to provide alternatives to this file, in order to avoid further confusion and to provide a clearer module structure.
Let me know what you think about
egg.json
below.Beta Was this translation helpful? Give feedback.
All reactions