Closed
Conversation
Marsup
requested changes
Jun 5, 2023
Contributor
Marsup
left a comment
There was a problem hiding this comment.
Same comment as the other PR, it needs to be included in lab's test suite.
Contributor
Author
@Marsup Not sure I follow what this means? I don't see much of a difference between this one and the other. |
Marsup
added a commit
that referenced
this pull request
Aug 4, 2023
Contributor
|
Superseded by #217. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Everything is the same as the DT typings, save for the fact that I removed the
namespace visionwrapper since it's locally scoped now. These are the only exceptions:Additions:
I added some interfaces to be able to type out the templates and layouts that exist. I usually end up overriding these myself anyway so I figured it'd be neat to expose that functionality. Look for
InViewTypesOr<T>within the types.I made
RenderMethodan exportable interface, along withRequestRenderMethod(request decoration), andToolkitRenderMethod. This is for the purpose of overloading them to include custom template/context configurations, which I normally do for views that have a hard requirement on context data types.I added documentation to the bottom of
API.md. Please review and let me know if this is OK!Fixes
The function
request.render(...)would yell whenever I'd try to define a layout because it wanted an{ engines }key. I assumed this was an error, since it is in the request lifecycle, and replaced it withViewHandlerOrReplyOptions.