Hi TheDiveO

> I would like to be able to drop an XML file, which conforms to a certain 
> schema, onto a TW5 instance. It should then be parsed and tiddlers created or 
> updated based on the XML file's contents.

The new bibtex plugin does exactly that:

https://github.com/Jermolene/TiddlyWiki5/blob/master/plugins/tiddlywiki/bibtex/deserializer.js
 
<https://github.com/Jermolene/TiddlyWiki5/blob/master/plugins/tiddlywiki/bibtex/deserializer.js>

It uses a third party library to actually parse the bibtex.

The main gotcha is that the deserializer is chosen based on the extension of 
the incoming file; there’s no way to give the user a choice over how an 
incoming XML file, say, should be interpreted. So you’ll have to adopt a file 
extension for your XML files.

> Is it possible to write custom "import modules"? If so, where can I find 
> examples, such as existing import modules?
“Deserializers” are the modules responsible for extracting tiddlers from a 
typed block of text.

> My XML file is going to be huge, several MB in size, and it would result in 
> around 10,000 small tiddlers. Feasible inside TW5 as to parsing?
Interesting. On another project I have been experimenting with importing large 
files and been somewhat surprised by how gracefully browsers cope with large 
amounts of data. But working under Node.js is much more reliable.

Best wishes

Jeremy

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWikiDev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/tiddlywikidev.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywikidev/A8A5D45A-9E34-4531-95A5-B54439DEC6FB%40gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to