mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-09-19 18:59:42 +00:00
2221b8e08a
* feat: added deserialize operator, tests and documentation * fix: correct typo in lingo file * fix: remove test that fails on node but succeeds in browser due to different availability of DOM deserializer
30 lines
831 B
Plaintext
30 lines
831 B
Plaintext
created: 20230601200356736
|
|
modified: 20230602105036887
|
|
tags: [[Operator Examples]] [[deserialize Operator]]
|
|
title: deserialize Operator (Examples)
|
|
type: text/vnd.tiddlywiki
|
|
|
|
\define html-data()
|
|
<!doctype html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<title>Test Data</title>
|
|
</head>
|
|
<body>
|
|
|
|
<!--~~ Ordinary tiddlers ~~-->
|
|
<div id="storeArea" style="display:none;"><div title="Hello "There"" type="text/vnd.tiddlywiki">
|
|
<pre>Abacus</pre>
|
|
</div>
|
|
</div>
|
|
<script class="tiddlywiki-tiddler-store" type="application/json">[{"title":"Hello \"There\"","text":"Calculator"},{"title":"Hello \"There\"","text":"Protractor"}]</script>
|
|
</body>
|
|
</html>
|
|
\end
|
|
|
|
This example uses the predefined variable `html-data`:
|
|
<$codeblock code=<<html-data>> language="HTML"/>
|
|
|
|
<<.operator-example 1 "[<html-data>deserialize[text/html]]">>
|