Closed pdehaan closed 2 years ago
The https://liquidjs.com/tags/overview.html page has 17 items in the sidebar and 17 in the table, but not the same 17 items.
$$(".sidebar-link + .sidebar-link").map(a => a.innerText);
// (17) ['assign', 'capture', 'case', 'comment', 'cycle', 'decrement', 'echo', 'for', 'if', 'include', 'increment', 'layout', 'liquid', 'raw', 'render', 'tablerow', 'unless']
$$("table > tbody td+td+td").flatMap(tag => tag.innerText.split(", ")).sort();
// (17) ['assign', 'case', 'comment', 'cycle', 'decrement', 'else', 'elsif', 'for', 'if', 'include', 'increment', 'layout', 'raw', 'render', 'tablerow', 'unless', 'when']
TAG | SIDEBAR | TABLE | NOTES |
---|---|---|---|
assign |
:heavy_check_mark: | :heavy_check_mark: | |
capture |
:heavy_check_mark: | :x: | |
case |
:heavy_check_mark: | :heavy_check_mark: | |
comment |
:heavy_check_mark: | :heavy_check_mark: | |
cycle |
:heavy_check_mark: | :heavy_check_mark: | |
decrement |
:heavy_check_mark: | :heavy_check_mark: | |
echo |
:heavy_check_mark: | :x: | |
else |
:x: | :heavy_check_mark: | See if page |
elsif |
:x: | :heavy_check_mark: | See if page |
for |
:heavy_check_mark: | :heavy_check_mark: | |
if |
:heavy_check_mark: | :heavy_check_mark: | |
include |
:heavy_check_mark: | :heavy_check_mark: | |
increment |
:heavy_check_mark: | :heavy_check_mark: | |
layout |
:heavy_check_mark: | :heavy_check_mark: | |
liquid |
:heavy_check_mark: | :x: | |
raw |
:heavy_check_mark: | :heavy_check_mark: | |
render |
:heavy_check_mark: | :heavy_check_mark: | |
tablerow |
:heavy_check_mark: | :heavy_check_mark: | |
unless |
:heavy_check_mark: | :heavy_check_mark: | |
when |
:x: | :heavy_check_mark: | See case page |
// $$(".sidebar-link + .sidebar-link").map(a => a.innerText); // 17 tags
const sidebarTags = ['assign', 'capture', 'case', 'comment', 'cycle', 'decrement', 'echo', 'for', 'if', 'include', 'increment', 'layout', 'liquid', 'raw', 'render', 'tablerow', 'unless']
// $$("table > tbody td+td+td").flatMap(tag => tag.innerText.split(", ")).sort(); // 17 tags
const tableTags = ['assign', 'case', 'comment', 'cycle', 'decrement', 'else', 'elsif', 'for', 'if', 'include', 'increment', 'layout', 'raw', 'render', 'tablerow', 'unless', 'when']
const allTags = new Set([...sidebarTags, ...tableTags].sort()); // 20 tags
for (const tag of allTags) {
console.log(`\`${tag}\` | ${boolEmoji(sidebarTags.includes(tag))} | ${boolEmoji(tableTags.includes(tag))}`);
}
function boolEmoji(value) {
return !!value ? ":heavy_check_mark:" : ":x:";
}
Re: https://liquidjs.com/filters/overview.html
I noticed that the
json
filter wasn't listed in the table, so I wrote a quick little scraper that verified the sidebar links vs the table values.TLDR: The
at_least
,at_most
,compact
,default
,json
, andsize
filters aren't listed in the table.