1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2025-12-05 08:18:06 +00:00

Get rid of the wikivocabulary object

This commit is contained in:
Jeremy Ruston
2012-12-26 22:02:59 +00:00
parent cbc08fcc1c
commit c703fb1267
8 changed files with 49 additions and 84 deletions

View File

@@ -356,11 +356,6 @@ exports.clearCache = function(title) {
}
};
exports.new_initParsers = function() {
// Create a default vocabulary
this.vocabulary = new $tw.WikiVocabulary({wiki: this});
};
/*
Parse a block of text of a specified MIME type
type: content type of text to be parsed
@@ -370,7 +365,11 @@ Options include:
parseAsInline: if true, the text of the tiddler will be parsed as an inline run
*/
exports.new_parseText = function(type,text,options) {
return this.vocabulary.parseText(type,text,options);
options = options || {};
return new $tw.WikiParser(type,text,{
parseAsInline: options.parseAsInline,
wiki: this.wiki
});
};
/*