mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-04-07 03:06:56 +00:00
Merge 0cc2a52b56ca4c76ee443aaf39fc95fa98e50569 into 8bda28afd5082bbf3f77482990f476ca6764df17
This commit is contained in:
commit
3c6a50cae2
@ -1,26 +0,0 @@
|
||||
/*\
|
||||
title: $:/editions/tw5.com/if-macro.js
|
||||
type: application/javascript
|
||||
module-type: macro
|
||||
\*/
|
||||
(function(){
|
||||
|
||||
/*jslint node: true, browser: true */
|
||||
/*global $tw: false */
|
||||
"use strict";
|
||||
|
||||
exports.name = ".if";
|
||||
|
||||
exports.params = [
|
||||
{ name: "cond" },
|
||||
{ name: "then" },
|
||||
{ name: "else" }
|
||||
];
|
||||
|
||||
exports.run = function(cond, then, elze) {
|
||||
then = then || "";
|
||||
elze = elze || "";
|
||||
return cond ? then : elze;
|
||||
};
|
||||
|
||||
})();
|
Loading…
x
Reference in New Issue
Block a user