Closed checketts closed 1 year ago
Sorry I did not have time sooner to look into this. I had a look now and I also looked at Java8TimeExpressionFactory.java. I am wondering why we need to extend from SpringStandardExpressionObjectFactory
. Can't we just implement the interface like Java8TimeExpressionFactory
does?
There is also a small typo in the class name HtmxSpringStandardExressionObjectFactory
-> Exression
should be Expression
Sorry I did not have time sooner to look into this. I had a look now and I also looked at Java8TimeExpressionFactory.java. I am wondering why we need to extend from SpringStandardExpressionObjectFactory
. Can't we just implement the interface like Java8TimeExpressionFactory
does?
There is also a small typo in the class name HtmxSpringStandardExressionObjectFactory
-> Exression
should be Expression
OK I think you are right. I'll try that approach. Thanks for the recommendation.
I suppose this can be merged, or is there anything you still want to change?
It can be merged.
See https://www.thymeleaf.org/doc/tutorials/3.0/usingthymeleaf.html#expression-utility-objects
This adds a
#htmxRequest
object that can be used similar to#request
in Thymeleaf templates.This change subclasses the
SpringStandardExpressionObjectFactory
to extend it. I'm not sure if there is a better extension technique.