Hi folks,
Using the Code by Zapier Javasrcipt to convert a text string to an Evernote checkbox list. Here is the code Im using:
// Assuming 'taskString' is your input variable containing tasks separated by commas
const tasks = inputData.taskString.split(',');
// Building the ENML content for Evernote
let enmlContent = "<en-note>";
tasks.forEach(task => {
// Clean up task to ensure no leading/trailing whitespace
task = task.trim();
// Append each task wrapped with <div> and <en-todo>
enmlContent += `<div><en-todo></en-todo>${task}</div>`;
});
/ Closing the <en-note> tag
enmlContent += "</en-note>";
// Outputting the formatted ENML content
output = {enmlContent: enmlContent};
However I keep getting an erorr stating ‘Content of submitted note was malformed.’
I’ve reviewed the evernote ENML guidelines and dont see any issue.
Any help much appreciated,