feat: add scalar configuration#4162
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #4162 +/- ##
=======================================
Coverage 98.38% 98.38%
=======================================
Files 348 348
Lines 15884 15889 +5
Branches 1754 1755 +1
=======================================
+ Hits 15627 15632 +5
Misses 121 121
Partials 136 136 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Generally a good approach, but I'm not sure we need the config object at all. You could just add the options as arguments to the plugin directly, as it's already specialised for scalar.
One option to do this would be to just accept a Actually, I think this is the right approach, because otherwise we'd always have to make Litestar release before a new scalar option could be used. |
|
Looks good! If you address the missing coverage, this can go in! |
|
Documentation preview will be available shortly at https://litestar-org.github.io/litestar-docs-preview/4162 |
|
i see this PR already merged to main, is the documentation not exist? https://docs.litestar.dev/2/search.html?q=ScalarConfig |
Description
Hello! I'm currently work on adding scalar configuration and during work got some questions:
I'm not sure about config
dataclassobject location. Maybe it must be somewhere else?versionarg inScalarRenderPlugin. So should we somehow detect difference?Closes
#3951