Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: add missing scripts key and allow extensibility #11

Merged
merged 1 commit into from
Jun 20, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 4 additions & 2 deletions src/types/packagejson.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ export interface PackageJson {
/**
* The name is what your thing is called.
* Some rules:

- The name must be less than or equal to 214 characters. This includes the scope for scoped packages.
- The name can’t start with a dot or an underscore.
- New packages must not have uppercase letters in the name.
- The name ends up being part of a URL, an argument on the command line, and a folder name. Therefore, the name can’t contain any non-URL-safe characters.

*/
name?: string
/**
Expand Down Expand Up @@ -63,6 +63,7 @@ export interface PackageJson {
*/
directory?: string
}
scripts?: Record<string, string>
/**
* If you set `"private": true` in your package.json, then npm will refuse to publish it.
*/
Expand Down Expand Up @@ -152,4 +153,5 @@ export interface PackageJson {
string | Record<'import' | 'require' | string, string>
>
workspaces?: string[]
[key: string]: any
}