I have a lot of coding in FreeMarker template files for view layer in my app.
I was wondering if I can set a debug point with Eclipse. Is there any good plugin that I can use to debug FreeMarker template files?
FreeMarker is a template engine, written in Java, and maintained by the Apache Foundation. We can use the FreeMarker Template Language, also known as FTL, to generate many text-based formats like web pages, email, or XML files.
Comments: <#-- and --> Comments are similar to HTML comments, but they are delimited by <#-- and -->. Comments will be ignored by FreeMarker, and will not be written to the output.
Templates are written in the FreeMarker Template Language (FTL), which is a simple, specialized language (not a full-blown programming language like PHP). Usually, a general-purpose programming language (like Java) is used to prepare the data (issue database queries, do business calculations).
Freemarker does not provide a random number generator at the moment. You can implement a naive random number generator using the time ( . now ) as a seed, but it should never be a critical part of your program.
As far as I know, you cannot. A template file is a plain text file that the template engine reads into memory and then uses to produce a document that it writes to the response. It's not actually executable code. You can put a breakpoint in the template engine code and follow along what it replaces and how.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With