We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
java code:
JetContext context = new JetContext(); context.put("flag", Boolean.FALSE);
jetx:
======== IF语句:#if(flag)flag为true#else()flag为false#end ========
output
======== IF语句:flag为false========
version
1.1.0
The text was updated successfully, but these errors were encountered:
默认开启 trim.directive.line,会删除指令行两边的空白,所以 #end 后面的 \r\n 会删掉了。
trim.directive.line
#end
\r\n
一般是这么写的
#if(flag) flag为true #else() flag为false #end
考虑到如果 #if/#else/#end 内联的情况 (同一行), 可以优化一下,保留一个 \r\n
#if/#else/#end
不过内联的情况,一般建议使用三元表达式: ${flag ? "flag为true" : "flag为false"}
Sorry, something went wrong.
谢谢指点,很喜欢你的这个开源项目。 已经申请加入贵开发群,希望通过验证。 本人qq23007067
cc61156
subchen
No branches or pull requests
java code:
jetx:
output
version
The text was updated successfully, but these errors were encountered: