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

feat: more robust package publishing #130

Merged
merged 1 commit into from
Jul 10, 2021

Conversation

geigerzaehler
Copy link
Contributor

  • We add the prepack script to take care of building the distribution. This removes the extra build command from ./scripts/publish.js and makes it possible to use this package as a git dependency.
  • We remove the dist folder before packing to avoid including any unnecessary artifacts.
  • We explicitly generate type declarations with tsc. The rollup plugin only generates type declarations if output.dir instead of output.file is specified.

* We add the [`prepack` script][prepack] to take care of building the
  distribution. This removes the extra `build` command from
  `./scripts/publish.js` and makes it possible to use this package as a
  git dependency.
* We remove the `dist` folder before packing to avoid including any
  unnecessary artifacts.
* We explicitly generate type declarations with `tsc`. The rollup plugin
  only generates type declarations if `output.dir` instead of
  `output.file` is specified.

[prepack]: https://docs.npmjs.com/cli/v7/using-npm/scripts
@geigerzaehler geigerzaehler requested a review from a team as a code owner July 10, 2021 11:32
@codecov
Copy link

codecov bot commented Jul 10, 2021

Codecov Report

Merging #130 (f0e181d) into main (df23935) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #130   +/-   ##
=======================================
  Coverage   94.37%   94.37%           
=======================================
  Files           4        4           
  Lines         160      160           
  Branches       56       56           
=======================================
  Hits          151      151           
  Misses          9        9           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update df23935...f0e181d. Read the comment docs.

Copy link
Contributor

@gregjopa gregjopa left a comment

Choose a reason for hiding this comment

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

Great improvement! thanks @geigerzaehler 💯 🥇 👍

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.

None yet

2 participants