Copy link to clipboard
Copied
Checking around I don't see any.
I'm returning back to a document which I haven't touched in months. The json I am trying to pass is valid (console.log) before I create the payload and valid after (console.log) but a previously working tag is not rendering correct/any values. Really stumped.
TIA.
I stand corrected, it DOES work for me. It failed when Word inserted "smart" quotes. When I switched to NON smart quotes, it worked:
Copy link to clipboard
Copied
Nope, there shouldn't be. You said 'tag', so I assume you mean a Document Generation call. Can you share more details?
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Thanks for the quick response and look-see.
I've got some hashtags which I am passing to the docx template
const hashtags = fooHashtags.map((i) => '#' + i);
const compactedhashtags = hashtags.map(function (item) {
return item.replace(/\s+/g, '').toLowerCase();
});
sampleData = {
<other variables>
hashtags: compactedhashtags,
}
In the docx, using this to get all on one line, {{ $join(hashtags,", ") }} which used to return the expected result but now returns 'hashtags'.
Copy link to clipboard
Copied
I can confirm it isn't working. Are you sure it did before? If so, I'll log the bug. Please note that in the meantime, you could just do the join in your code, w/ a reduce() call for example.
Copy link to clipboard
Copied
I stand corrected, it DOES work for me. It failed when Word inserted "smart" quotes. When I switched to NON smart quotes, it worked:
Copy link to clipboard
Copied
Thanks, I did the join in my code and back on track.
Copy link to clipboard
Copied
A bit above my paygrade, but could there be any issues with Libreoffice and .docx formats re: picking up tags. Or with AWS Lambda(?). There's an inconsistency I can't figure out. I came across another instance whereas a simple input is not being rendered.
I.E.
# inputs:
# console.log output:
2022-10-27T02:48:23.306Z INFO sampleData--> {
totalBingIssues: 9
}
# docx: thie tag remains, no results
Our tools picked up {{totalBingIssues}} potential issues.
Copy link to clipboard
Copied
*the
Copy link to clipboard
Copied
Can you share your Word file and I'll see if I can recreate? Did you ever open the file in Word, or just LibreOffice?
FYI, the issue with smart quotes - I reported it internally.
Copy link to clipboard
Copied
Copy link to clipboard
Copied
I'm not able to recreate this. Opened it in Word, set totalBingIssues to 9 in JSON, and it rendered just fine.
Copy link to clipboard
Copied
Wow, ok. I'll tinker some more. Thanks.