-
Notifications
You must be signed in to change notification settings - Fork 103
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
Support passing pg-promise initialization options during the library's initialization #94
Comments
I think allowing the constructor to be extended with options is a good choice. Please make a pull request and let's look at it together. Also could you elaborate on what you want to build on top of schemats, I'm very curious. |
My sentiment exactly, what options of |
@xiamx I actually have (at least for now) decided that this is a bit heavy for me to implement/use (for now, at least), and I can't really devote time to make a pull request currently, sorry. I was planning to use this to generate types during build/development. The project I work on has some special logic for getting the database configuration, and use that as a configuration object for pg-promise in the main source. I didn't have a specific idea for initialization options though. As I said, I won't be using this right now, so feel free to close this issue if you don't think it's needed. |
Cool so I changed the title to a more descriptive one. We will keep this one open for visibility. |
@xiamx It's nice, but I don't see it being of any use, because this library is only used for generating code, and all the options in pg-promise relate to the run-time in-app usage only, nothing to do with the code generation. I don't understand why this issue was open to begin with. |
It would be nice to be able to pass initialization options or a configuration object directly to pg-promise.
This could be fairly easily be possible if you
PgPromise.IDatabase
or a string directly to be passed to the PostgresDatabase constructor.In general, it might be worth double checking to see if there are other useful classes/functions that should be exported too.
The text was updated successfully, but these errors were encountered: