1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-11-27 20:10:03 +00:00
TiddlyWiki5/core/modules/widgets/storyviews.js

30 lines
573 B
JavaScript

/*\
title: $:/core/modules/filters/storyviews.js
type: application/javascript
module-type: filteroperator
Filter operator for returning the names of the story views in this wiki
\*/
(function(){
/*jslint node: true, browser: true */
/*global $tw: false */
"use strict";
/*
Export our filter function
*/
exports.storyviews = function(source,operator,options) {
var results = [],
storyviews = {};
$tw.modules.applyMethods("storyview",storyviews);
$tw.utils.each(storyviews,function(info,name) {
results.push(name);
});
results.sort();
return results;
};
})();