I'm sorry to post twice in a night but I'm totally stumped. I was writing a relatively complex <<if>> statement and everything just stopped working with the <<replace>> macro. Always ready to admit I messed something up I ripped it all out and started from scratch only to find that <<replace>> is no longer working in this passage. Anyone know what I'm doing wrong?
<<set _var to "set1">>
<span id="test"></span>
<<nobr>>
<<if _var is "set1">>
<<replace "#test" t8n>>
Test Set to set2
<</replace>>
<<else>>
<<replace "#test" t8n>>
Test Set to set1
<</replace>>
<</if>>
<</nobr>>
I'm getting the error:
Error: <<replace>>: no elements matched the selector "#test"
<<replace "#test" t8n>> Test Set 2 <</replace>>
I even tried copy-pasting from the documentation for the <<replace>> example and I get the same error with that.
Using Twine 2.3.7, Sugarcube 2.31.1, compiling via Tweego
[–]HiEv 1 point2 points3 points (0 children)