1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-11-16 23:04:50 +00:00

Starting to implement cooking down the rabbithole

The idea is that rendering tiddlywiki5.template.html to text/plain will
cook the TiddlyWiki HTML file
This commit is contained in:
Jeremy Ruston 2012-05-05 11:24:45 +01:00
parent a6ea68b29a
commit 8203437a4f
4 changed files with 31 additions and 3 deletions

View File

@ -0,0 +1,23 @@
/*\
title: $:/core/modules/macros/serialize.js
type: application/javascript
module-type: macro
\*/
(function(){
/*jslint node: true, browser: true */
/*global $tw: false */
"use strict";
exports.info = {
name: "serialize",
params: {}
};
exports.executeMacro = function() {
return [];
};
})();

View File

@ -1,3 +1,6 @@
title: $:/core/tiddlywiki5.template.html
type: text/x-tiddlywiki-html
<<! <<!
A mockup of a template for new-style generation of TiddlyWiki HTML files A mockup of a template for new-style generation of TiddlyWiki HTML files
@ -17,7 +20,7 @@ A mockup of a template for new-style generation of TiddlyWiki HTML files
<meta name="copyright" content=" <meta name="copyright" content="
[[$:/core/copyright.txt]] [[$:/core/copyright.txt]]
" /> " />
<title>[[$:/shadows/title]]</title> <title><<tiddler target:$:/shadows/title>></title>
<style id="styleArea" type="text/css"> <style id="styleArea" type="text/css">
<<serialize filter:"[is[shadow]type[text/css]]" as:styleblock>> <<serialize filter:"[is[shadow]type[text/css]]" as:styleblock>>
</style> </style>

View File

@ -5,7 +5,7 @@ version: core/version.txt
jsbootstart: core/bootprefix.js jsbootstart: core/bootprefix.js
jsbootend: core/boot.js jsbootend: core/boot.js
shadow: core/tiddlywiki5.template.html shadow: core/tiddlywiki5.template.html.tid
title: $:/core/tiddlywiki5.template.html title: $:/core/tiddlywiki5.template.html
shadow: core/copyright.txt shadow: core/copyright.txt
title: $:/core/copyright.txt title: $:/core/copyright.txt

View File

@ -2,7 +2,9 @@
# run TiddlyWiki5 # run TiddlyWiki5
node ../core/boot.js --verbose --wikitest ../../test/wikitests/ --dump shadows || exit 1 node ../core/boot.js --verbose --wikitest ../../test/wikitests/ || exit 1
node ../core/boot.js --verbose --savetiddler $:/core/tiddlywiki5.template.html ../tmp/tw5/rabbit.html text/plain || exit 1
# run jshint # run jshint
jshint ../core/*.js jshint ../core/*.js