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

NPM plugin #70

Merged
merged 13 commits into from
Jun 19, 2018
Merged

NPM plugin #70

merged 13 commits into from
Jun 19, 2018

Conversation

giladgray
Copy link
Contributor

@giladgray giladgray commented Jun 19, 2018

  • new sourceBaseDir option for Documentalist controls relative pathing for sourcePath in MD and NPM
  • new NpmPlugin!
    • excludePrivate, excludePaths options
    • parses package.json files, gets more data from npm info if possible (async call to npm registry)
      • if package is private or unpublished then it uses available package.json
    • emits name, desc, latest/next, all versions

@blueprint-bot
Copy link

Capitalization

Preview: docs

@blueprint-bot
Copy link

use dm.relativePath

Preview: docs

@blueprint-bot
Copy link

use relativePath in markdown plugin

Preview: docs

Copy link
Contributor

@themadcreator themadcreator left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

questions

src/launch.ts Outdated
@@ -15,7 +16,9 @@ import { TypescriptPlugin } from "./plugins/typescript";
// Set breakpoints in original .ts source and debug in the editor!
Documentalist.create()
.use(".ts", new TypescriptPlugin())
.use(".json", new NpmPlugin())
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is too broad, it should only apply to package.jsons.

name: data.name,
// tslint:disable-next-line:object-literal-sort-keys
description: data.description,
latestVersion: data["dist-tags"].latest,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this guaranteed to be non-null? what about not-yet released libraries?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes good catch. un-released libraries will actually die here because npm info will return nothing

@blueprint-bot
Copy link

add private/published properties to npm package, add excludeNames/excludePrivate options

Preview: docs

@blueprint-bot
Copy link

comment

Preview: docs

@giladgray giladgray merged commit 361dc6b into master Jun 19, 2018
@giladgray giladgray deleted the gg/npm branch June 19, 2018 23:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants