Open
Description
Copied verbatim from nodejs/package-maintenance#404 by @darcyclarke
create-pkg
Goals:
- Provide a tool that promotes sane package defaults (defined by PMWG)
- Provide tools to extend defaults per community/team
Example Usage:
$ npm init pkg
$ npx create-pkg
const pkg = require('create-pkg')
import pkg from 'create-pkg'
Questions:
- What do we want the scaffold output to include?
package.json
name
description
homepage
author
license
funding
version
type
main
scripts
"prepublish": "..."
* (contentious)"test": "..."
* (contentious)
exports
index.js
LICENSE
CONTRIBUTING.md
CODE_OF_CONDUCT.md
README.md
FUNDING.yml
* (contentious).npmrc
* (contentious).gitignore
* (contentious)- Contents:
/node_modules
- Contents:
.github/ISSUE_TEMPLATES/*
* (contentious)
- What API surface do we want to expose to both end users and folks who want to compose the base generator with their own custom opinions?
- Interfaces: CLI w/ Interactive/Prompts & a JS API
Next Steps:
- Get some general consensus of the approach we'd like to take building this & the defaults we'd want
- Update
@pkgjs/support
to be a consumer of this tool or vice-versa
References & Prior Art:
- Github gitignore: https://github.com/github/gitignore/blob/master/Node.gitignore
- Collection user input: https://github.com/wesleytodd/opta
- Yeoman
- Plop
npm init x
(ie.$ npx create-x
)- And probably many many more scaffolding tools/generators...
Metadata
Assignees
Labels
No labels