Replies: 1 comment 5 replies
-
Whew, maybe our jobs are safe for a while yet :P In any case, it should work if the nodes passed to the isn are wrapped in a list |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi LuaSnip enthusiasts,
I had these two snippets a while ago, the former works as expected for its simplicity, and for some arbitrary reasons I moved to the latter one and struggled to interpret its meaning. I asked ChatGPT and I got this answer.
s("do", fmt("do\n\t{1}\nend", i(1, "--do_body")))
s("do", { isn(1, t({ "do", "" }), i(1, "--do_body"), "") })
The logics from the AI's answer sound reasonable, the 2nd snippet worked before but now I got the error bellow. Could someone kindly explain to me what are the advantages of the second snippet over the first one and what the error means please?
Beta Was this translation helpful? Give feedback.
All reactions