mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-11-08 03:23:00 +00:00
Added reveal macro
This commit is contained in:
@@ -24,6 +24,17 @@ exports.trim = function(str) {
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
Convert a string to base64 encoding
|
||||
*/
|
||||
exports.toBase64 = function(str) {
|
||||
if($tw.browser) {
|
||||
return window.btoa(str);
|
||||
} else {
|
||||
new Buffer(str).toString("base64");
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
Return the number of keys in an object
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user