-
Notifications
You must be signed in to change notification settings - Fork 63
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(plugin-core): new plugin-core package #1193
Conversation
packages/plugin-core/src/types.ts
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would go for type declaration instead of interfaces:
export type HbPluginOptions = {
// ....
}
|
||
## Usage | ||
|
||
You shouldn't need to use this package directly. This package serves as the core implementation of shared functionality meant to be used within Honeybadger's plugins for JS build/bundling systems such as [webpack](https://github.com/honeybadger-io/honeybadger-js/tree/master/packages/webpack) and [rollup](https://github.com/honeybadger-io/honeybadger-js/tree/master/packages/rollup-plugin). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@subzero10 I modeled this README on the core
package, which is available to the public but not encouraged for people to use. I think we actually may find circumstances later in which this may be useful for people to use directly... basically any time we recommend someone hit the sourcemap upload or deploy notification API in JS-land, they could probably use this instead. But I'd say let's use it for our own purposes first, and then decide if we want our users to use it or not later.
Status
READY
Description
Part of #1013.
This PR creates a
plugin-core
package, which extracts the aspects of therollup-plugin
andwebpack
packages that can be shared between the two. This will mean that we have consistency between these two packages (and any further build plugins) in the following areas:This package includes aspects of both existing packages, mostly from https://github.com/honeybadger-io/honeybadger-js/blob/master/packages/rollup-plugin/src/hbUtils.ts and https://github.com/honeybadger-io/honeybadger-js/blob/master/packages/webpack/src/resolvePromiseWithWorkers.js.
There will be follow-up PRs to have
webpack
androllup-plugin
depend onplugin-core
.Todos