analog
analog copied to clipboard
Update nitropack version
Which scope/s are relevant/related to the feature request?
vite-plugin-nitro
Information
@analog/platformdepends on 2.6.0 nitropack version.
Updating to the latest version would allow, among other things, to explore experimental support to websotckets and built-in swagger UI and openapi auto-generated definition.
Describe any alternatives/workarounds you're currently using
No response
I would be willing to submit a PR to fix this issue
- [X] Yes
- [ ] No
looking forward to this. if needed I can also work on this.
Sounds good. Shouldn't be a breaking change
Hi @nckirik feel free to contribute if you want to :)
It seems we'll need to wait for [email protected] to be released.
Especially for the openAPI "root" configuration. Currently, it is only available in nitro's nightly channel.
As @brandonroberts mentioned before, all other config options correctly reflect directly from Nitro's NitroConfig type.
Nitro's config documentation regarding these experimental options appears somewhat misleading, in my opinion.
Initially when we were discussing this with @geromegrignon, I assumed a syntax similar to the following for configuring openAPI within Nitro's config.
nitro: {
...
experimental: {
openAPI: {
meta: {
title: 'My Awesome Project',
description: 'This might become the next big thing.',
version: '1.0'
}
}
...
}
...
}
However, it turns out this assumption was incorrect. In reality, openAPI config should be a boolean to enable the experimental feature and a separate root config object to configure it, like so:
nitro: {
experimental: {
openAPI: true,
},
openAPI: {
meta: {
title: 'My Awesome Project',
description: 'This might become the next big thing.',
version: '1.0',
},
},
},
And since this openAPI root configuration is only available in the nightly build, I think there is nothing to do for now.
Thanks for the feedback. I assumed about the same for openapi 😅
I think the latest 2.9.x release of nitropack includes these features