getNodeFilter(type) {

    const filter = $tw.wiki.getCacheForTiddler(this.nodeFilterTRef, "tmap-nodeFilter", () => {

      let filter = utils.makeHashMap();
      const tObj = $tw.wiki.getTiddler(this.nodeFilterTRef);

      filter.raw = (tObj && tObj.fields.filter) || '';
      filter.pretty = utils.getPrettyFilter(filter.raw);
      filter.compiled = $tw.wiki.compileFilter(filter.raw);

      return filter;

    });

    return (type ? filter[type] : filter);

  }
Method will return a tiddlywiki node filter that is used to
decide which nodes are displayed by the graph.

@param {("raw"|"pretty"|"compiled")} [type] - Use this param to control the output type.
@result {*}
    Depends on the type param:
    - raw: the original filter string
    - pretty: the prettyfied filter string for usage in textareas
    - compiled: {Array<string>} all matches