github blacksmithgu/obsidian-dataview 0.4.4

latest releases: 0.5.67, 0.5.66, 0.5.65...
3 years ago

0.4.4

Feature release with some bugfixes for flatten and group by.

Lambdas

Adds basic lambda support to the dataview query language along with some functions which accept it. Lambdas have the
form (arg1, arg2, ...) => expression; for example:

(x) => x + 2
(tag) => contains(tag, "yes")
(a, b) => a + b

The following methods have been updated to support lambdas:

  • any(list, lambda): Returns true if the lambda returns true for any value in the list.
  • all(list, lambda): Returns true if the lambda returns true for all values in the list.
  • none(list, lambda): Returns true if the lambda returns true for no values in the list.
  • map(list, lambda): Returns a new list where the lambda has been applied to each element.
  • filter(list, lambda): Returns a new list consisting only of elements that the lambda returned true for.

Primitive Lists & Objects

You can write lists using a primitive JavaScript-like syntax: [1, 2, 3]; you can additionally write objects using a
primitive JavaScript-like syntax: { key1: value1, key2: value2 }. These are mostly useful for complicated sort and
equality checks, though will be more useful in the future as subqueries and complex FROM statements are added.

Bugs

  • #378: Fixes some list rendering.
  • #398: Fixes issues with the FLATTEN statement.

Don't miss a new obsidian-dataview release

NewReleases is sending notifications on new releases.