question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

JSLT does not produce itself: empty objects

See original GitHub issue

Hi there,

Just getting started with JSLT so may have misunderstood something, but I would have expected this JSLT program to be self-producing: {"foo": {}}

Instead the playground outputs an empty object: { }

The behavior seems to be that if a dictionary value is the empty object anywhere in the JSON document, then the key is omitted from the output. Is this expected?

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:13 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
Mohammadcorecommented, Feb 7, 2019

@larsga I haven’t got the time to test it yet. But from the quick look I had at the code changeset, looked fulfilling the requirement. Thank you very much.

0reactions
larsgacommented, Feb 7, 2019

I consider this solved, now that we have configurable filters for which values to leave out. Please reopen if you disagree.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Does any one know how to create Empty Array In JSTL (JSP ...
The only way that I could think of is to use the useBean tag to create an ArrayList. Its add method returns a...
Read more >
JSLT - Apache Camel
The Jslt component allows you to process a JSON messages using an JSLT expression. This can be ideal when doing JSON to JSON...
Read more >
c:when trouble in jstl with a map object - Oracle Communities
I have the following line in my jsp file: <c:when test="${mybean.propertyMap.isEmpty}"> propertyMap is a TreeMap object.
Read more >
5 JSTL Core IF Tag Examples in JSP - Tutorial - Javarevisited
Earlier we have seen examples of JSTL foreach tag and JSTL core set tag and ... If test expression results in false than...
Read more >
JSP - Expression Language (EL) - Tutorialspoint
JSP EL allows you to create expressions both (a) arithmetic and (b) logical. ... you to access various attributes of Java Beans and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found