You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The more I am thinking about this, the more I think this is not the right default for this package but should instead be set in a more opinionated wrapper layer like https://github.com/pkgjs/create-pkg
I say this specifically because the default for Node.js iscommonjs. As in, adding a type by default here would mean deviation from the default experience you get when you do npm init -y && cat "console.log('hello') > index.js && node index.js.
So, while I agree that this is likely the more future proof default to set, I would like to align this package with the platform defaults and allow the more opinionated layers above to provide those opinions. I will leave this open as a discussion point, but I think I might be fairly set on this specific opinion.
Activity
wesleytodd commentedon Nov 12, 2024
For anyone who wants to open this PR: https://github.com/pkgjs/create-package-json/blob/main/index.js#L125
AugustinMauroy commentedon Nov 12, 2024
I'll do it !
wesleytodd commentedon Dec 18, 2025
The more I am thinking about this, the more I think this is not the right default for this package but should instead be set in a more opinionated wrapper layer like https://github.com/pkgjs/create-pkg
I say this specifically because the default for Node.js is
commonjs. As in, adding atypeby default here would mean deviation from the default experience you get when you donpm init -y && cat "console.log('hello') > index.js && node index.js.So, while I agree that this is likely the more future proof default to set, I would like to align this package with the platform defaults and allow the more opinionated layers above to provide those opinions. I will leave this open as a discussion point, but I think I might be fairly set on this specific opinion.