From 0c46233ec310bd9a3ae925180a1c8ec2acb5ecf1 Mon Sep 17 00:00:00 2001 From: Joe Kendall Date: Mon, 1 Jul 2024 11:02:03 -0400 Subject: [PATCH] adding recent additions to logic reference and updating the template list to include all available templates --- src/components/TemplateList.astro | 113 ++++++++++++++++++++-------- src/content/docs/logic-reference.md | 70 +++++++++++++++-- 2 files changed, 143 insertions(+), 40 deletions(-) diff --git a/src/components/TemplateList.astro b/src/components/TemplateList.astro index 618e6b9..dc27273 100644 --- a/src/components/TemplateList.astro +++ b/src/components/TemplateList.astro @@ -1,4 +1,23 @@ - +--- +const node_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/nodejs/nodejs-original.svg' +const django_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/django/django-plain.svg' +const pg_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/postgresql/postgresql-plain.svg' +const dynamo_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/dynamodb/dynamodb-plain.svg' +const vue_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/vuejs/vuejs-original.svg' +const go_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/go/go-original-wordmark.svg' +const mysql_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/mysql/mysql-original.svg' +const python_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/python/python-original.svg' +const rust_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/rust/rust-original.svg' +const elixir_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/elixir/elixir-plain.svg' +const phoenix_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/phoenix/phoenix-original.svg' +const astro_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/astro/astro-original.svg' +const java_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/java/java-original.svg' +const spring_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/spring/spring-original.svg' + +const ts_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/typescript/typescript-plain.svg' +const next_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/nextjs/nextjs-plain.svg' +const svelte_icon = 'https://cdn.jsdelivr.net/gh/devicons/devicon@latest/icons/svelte/svelte-plain.svg' +---
@@ -7,24 +26,25 @@

Nodejs with Vue and Amazon DynamoDB

- + +
+

Java with SpringBoot and Postgres

+
+ +
+
@@ -123,6 +170,6 @@ diff --git a/src/content/docs/logic-reference.md b/src/content/docs/logic-reference.md index 2fd207e..d4f02b8 100644 --- a/src/content/docs/logic-reference.md +++ b/src/content/docs/logic-reference.md @@ -7,7 +7,6 @@ order: 5 --- - ## add Add a list of numbers together. Strings will be converted to numbers, null is treated as 0. @@ -1909,6 +1908,63 @@ reduce: ``` +## search + +Determines whether a substring is present within a log entry's search string, returns a boolean. + +### Return Value + +(`boolean`) + +### Parameters + +#### searchElement (`number`, `string`, `boolean`, `null`) + +### Examples + + +*Example 1* + +```yaml +search: foobar + +``` + +*Returns* + +```json +false +``` + + +*Example 2* + +```yaml +search: 123 + +``` + +*Returns* + +```json +false +``` + + +*Example 3* + +```yaml +search: true + +``` + +*Returns* + +```json +false +``` + + ## slice Returns a portion of an array selected from start to end (end not included) where start and end represent the index of items in that array. @@ -2115,7 +2171,7 @@ Determines whether a string starts with the characters of this search string. Nu *Example 1* ```yaml -endswith: +startswith: - Hello, friend - Hello @@ -2124,14 +2180,14 @@ endswith: *Returns* ```json -false +true ``` *Example 2* ```yaml -endswith: +startswith: - 42 - 4 @@ -2140,14 +2196,14 @@ endswith: *Returns* ```json -false +true ``` *Example 3* ```yaml -endswith: +startswith: - Hello, friend - friend @@ -2156,7 +2212,7 @@ endswith: *Returns* ```json -true +false ```