Feature: Add an API for giving workers more helpers
- Dominant language
- TypeScript
- Stars
- 2.4k
- Forks
- 126
- Avg merge
- 2d 2h
- Merged PRs (30d)
- 9
Description
**Usecase**
Give users of graphile-worker the ability to pass in custom helpers. This could include custom database connection objects, metadata, application-specific helpers, etc...
For example:
My specific usecase is to pass a Slonik database connection object.
**Implementation**
https://github.com/graphile/worker/blob/1d4fa8c08f10f49eaca2343365a5db2b477206bf/src/helpers.ts#L71
It looks like if [this](https://github.com/graphile/worker/blob/1d4fa8c08f10f49eaca2343365a5db2b477206bf/src/helpers.ts#L71
) TODO was done, this usecase could be satisified.
I'm not sure what the ultimate implementation would look like. Would there be a specific file like `helpers.ts` that would be loaded and named exports would automatically be included?
**Pitfalls/Things to watch out for**
- Naming conflicts with existing helpers -- Is it okay to override?
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.