From c96d02a6316419e6a123de7c18fa26dd6c17baa6 Mon Sep 17 00:00:00 2001 From: Blessing Ene Anyebe Date: Fri, 24 May 2024 13:16:40 +0100 Subject: [PATCH 1/8] improved FAQ description text --- pages/overview/faq/index.page.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/overview/faq/index.page.tsx b/pages/overview/faq/index.page.tsx index 60e46e99a..19b9632fa 100644 --- a/pages/overview/faq/index.page.tsx +++ b/pages/overview/faq/index.page.tsx @@ -15,8 +15,8 @@ export default function Content() { {newTitle}

- Lorem ipsum dolor sit amet consectetur adipisicing elit. Nobis, totam? - Asperiores delectus perspiciatis, reprehenderit, harum quasi unde + Below you'll find answers to questions we get asked the most about JSON + Schema.

From 4536f32d6a20b102d01489eec686e5eb29e1e525 Mon Sep 17 00:00:00 2001 From: Blessing Ene Anyebe Date: Tue, 28 May 2024 01:30:38 +0100 Subject: [PATCH 2/8] Updated FAQ general questions --- data/faq.json | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/data/faq.json b/data/faq.json index 13ae1c384..f0b024e3e 100644 --- a/data/faq.json +++ b/data/faq.json @@ -2,49 +2,49 @@ { "id": 1, "question": "What is JSON Schema?", - "answer": "JSON Schema is a vocabulary that allows you to annotate and validate JSON documents. It defines the structure, data types, and constraints of JSON data.", + "answer": "JSON Schema is a specification for defining the structure of JSON data. It provides a standardized way to annotate, describe, and validate JSON data. JSON Schema defines content, structure, data types, and other expected constraints within a JSON document. The key aspects of JSON Schema include defining data structure, validation documentation data contracts, and diverse use cases.", "category": "general" }, { "id": 2, "question": "How do I create a simple JSON Schema?", - "answer": "You can create a simple JSON Schema using a JSON object with properties like 'type', 'properties', and 'required'. These define the data type, properties, and mandatory fields of your JSON document.", + "answer": "You create a simple JSON Schema by defining keywords such as 'schema', 'id', 'title', 'description', and 'type', which specify the version, unique identifier, title, and, description of your schema. Then, specify the data type for your schema will validate (e.g., object, array) and define the necessary properties, including their types and constraints. You can also include keywords like; 'properties', 'required', and 'default'. These define the constraints of your JSON document.", "category": "general" }, { "id": 3, "question": "What is the purpose of 'type' in JSON Schema?", - "answer": "The 'type' keyword specifies the data type of the JSON value. It can be 'string', 'number', 'object', 'array', 'boolean', 'null', or a combination of these.", + "answer": "The 'type' keyword defines the data type of the schema and guarantees that the validated data complies with the specified type. JSON Schema defines these types; 'string', 'number', 'integer', 'object', 'array', 'boolean', and 'null'. The type keyword primarily functions for data validation, compatibility across systems, and restriction of JSON documents.", "category": "general" }, { "id": 4, "question": "How can I define default values in a JSON Schema?", - "answer": "You can use the 'default' keyword to set a default value for a property in your JSON Schema. It provides a fallback value if the property is not present in the JSON document.", + "answer": "You can define default values for properties using the 'default' keyword, which provides a fallback value if the property is not present in the JSON document. This feature is useful for simplifying client-side code, generating documentation, creating forms, and mock data for testing, for example, in the schema {'type': 'object', 'properties': {'name': {'type': 'string', 'default': 'John Doe'}, 'age': {'type': 'integer', 'default': 30}}}, the 'name' and 'age' properties will default to 'John Doe' and 30 if not specified.", "category": "general" }, { "id": 5, "question": "What is the significance of 'required' in JSON Schema?", - "answer": "The 'required' keyword is an array that specifies which properties must be present in a JSON document. It enforces that these properties are not omitted.", + "answer": "The 'required' keyword ensures that specific properties must be present in the JSON data being validated. It specifies which properties are mandatory, avoids errors or incomplete processing by guaranteeing the provision of necessary data, and works for form validation, configuration files, schema evolution, etc.", "category": "general" }, { "id": 6, "question": "How can I validate a JSON document against a JSON Schema?", - "answer": "You can use various tools and libraries, such as AJV (Another JSON Schema Validator) in JavaScript, to validate a JSON document against a JSON Schema. These tools check if the document adheres to the specified schema rules.", + "answer": "You can use various tools and libraries, such as AJV (Another JSON Schema Validator), to validate a JSON document against a JSON Schema. It ensures the JSON data adheres to the expected format and constraints defined in the schema.", "category": "general" }, { "id": 7, "question": "What is the difference between 'object' and 'array' types in JSON Schema?", - "answer": "In JSON Schema, 'object' is used to define an object with named properties, while 'array' is used to define an ordered list of values. 'object' contains key-value pairs, whereas 'array' contains elements identified by their index.", + "answer": "The object type in JSON Schema represents a collection of key-value pairs, ideal for modeling entities with named properties, like a person with attributes such as name and age. In contrast, the array type represents ordered collections of items suited for sequences of similar elements, such as lists of strings or objects. Understanding these differences helps to describe and validate JSON data structures.", "category": "general" }, { "id": 8, "question": "Can I use JSON Schema to describe nested structures?", - "answer": "Yes, JSON Schema supports nested structures. You can define properties with their own JSON Schema, allowing you to describe complex hierarchical data.", + "answer": "JSON Schema allows for describing nested structures to represent complex, hierarchical data. You can define properties with their own JSON Schema, objects within objects, and arrays within objects or arrays, providing a flexible way to model various data relationships.", "category": "general" } ] From f17103a69725814df4036fdb54c8c6bd1c10d9bc Mon Sep 17 00:00:00 2001 From: Blessing Ene Anyebe Date: Tue, 28 May 2024 01:47:56 +0100 Subject: [PATCH 3/8] Updated FAQ description text for fix one-sentence bug --- pages/overview/faq/index.page.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pages/overview/faq/index.page.tsx b/pages/overview/faq/index.page.tsx index 19b9632fa..e6d620b3d 100644 --- a/pages/overview/faq/index.page.tsx +++ b/pages/overview/faq/index.page.tsx @@ -15,8 +15,9 @@ export default function Content() { {newTitle}

- Below you'll find answers to questions we get asked the most about JSON - Schema. + If you are new to JSON Schema this section will help you learn more + about JSON Schema and JSON data. Below you'll find answers to questions + we get asked the most about JSON Schema.

From 4b80cf3c3f0938aa51bbf17fa89c3bbcb8163731 Mon Sep 17 00:00:00 2001 From: Blessing Ene Anyebe <60541622+kwennB@users.noreply.github.com> Date: Tue, 28 May 2024 09:53:49 +0100 Subject: [PATCH 4/8] Update data/faq.json Co-authored-by: Benjamin Granados <40007659+benjagm@users.noreply.github.com> --- data/faq.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data/faq.json b/data/faq.json index f0b024e3e..bcc8e27e4 100644 --- a/data/faq.json +++ b/data/faq.json @@ -2,7 +2,7 @@ { "id": 1, "question": "What is JSON Schema?", - "answer": "JSON Schema is a specification for defining the structure of JSON data. It provides a standardized way to annotate, describe, and validate JSON data. JSON Schema defines content, structure, data types, and other expected constraints within a JSON document. The key aspects of JSON Schema include defining data structure, validation documentation data contracts, and diverse use cases.", + "answer": "JSON Schema is a specification for defining the structure of JSON data. It provides a standardized way to annotate, describe, and validate JSON data. JSON Schema defines content, structure, data types, and other expected constraints within a JSON document.", "category": "general" }, { From ef720d8255c43cdb72e16ee8c1bc750e368a90e3 Mon Sep 17 00:00:00 2001 From: Blessing Ene Anyebe <60541622+kwennB@users.noreply.github.com> Date: Tue, 28 May 2024 09:55:38 +0100 Subject: [PATCH 5/8] Update data/faq.json Co-authored-by: Benjamin Granados <40007659+benjagm@users.noreply.github.com> --- data/faq.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data/faq.json b/data/faq.json index bcc8e27e4..d3649ca28 100644 --- a/data/faq.json +++ b/data/faq.json @@ -8,7 +8,7 @@ { "id": 2, "question": "How do I create a simple JSON Schema?", - "answer": "You create a simple JSON Schema by defining keywords such as 'schema', 'id', 'title', 'description', and 'type', which specify the version, unique identifier, title, and, description of your schema. Then, specify the data type for your schema will validate (e.g., object, array) and define the necessary properties, including their types and constraints. You can also include keywords like; 'properties', 'required', and 'default'. These define the constraints of your JSON document.", + "answer": "You can create a simple JSON Schema using a JSON object with properties like 'type', 'properties', and 'required'. These define the data type, properties, and mandatory fields of your JSON document.", "category": "general" }, { From 4a2b511cd9c8318eb2137a686a9a33664c5b9826 Mon Sep 17 00:00:00 2001 From: Blessing Ene Anyebe <60541622+kwennB@users.noreply.github.com> Date: Tue, 28 May 2024 09:55:59 +0100 Subject: [PATCH 6/8] Update data/faq.json Co-authored-by: Benjamin Granados <40007659+benjagm@users.noreply.github.com> --- data/faq.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data/faq.json b/data/faq.json index d3649ca28..4da14e6d0 100644 --- a/data/faq.json +++ b/data/faq.json @@ -20,7 +20,7 @@ { "id": 4, "question": "How can I define default values in a JSON Schema?", - "answer": "You can define default values for properties using the 'default' keyword, which provides a fallback value if the property is not present in the JSON document. This feature is useful for simplifying client-side code, generating documentation, creating forms, and mock data for testing, for example, in the schema {'type': 'object', 'properties': {'name': {'type': 'string', 'default': 'John Doe'}, 'age': {'type': 'integer', 'default': 30}}}, the 'name' and 'age' properties will default to 'John Doe' and 30 if not specified.", + "answer": "You can use the 'default' keyword to set a default value for a property in your JSON Schema. It provides a fallback value if the property is not present in the JSON document.", "category": "general" }, { From cf68db2dc42a7a9874852e471fa0acc50a5448fa Mon Sep 17 00:00:00 2001 From: Benjamin Granados <40007659+benjagm@users.noreply.github.com> Date: Tue, 28 May 2024 11:44:57 +0200 Subject: [PATCH 7/8] Update pages/overview/faq/index.page.tsx --- pages/overview/faq/index.page.tsx | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/pages/overview/faq/index.page.tsx b/pages/overview/faq/index.page.tsx index e6d620b3d..220f0f7e4 100644 --- a/pages/overview/faq/index.page.tsx +++ b/pages/overview/faq/index.page.tsx @@ -15,9 +15,7 @@ export default function Content() { {newTitle}

- If you are new to JSON Schema this section will help you learn more - about JSON Schema and JSON data. Below you'll find answers to questions - we get asked the most about JSON Schema. + Below you'll find answers to questions we get asked the most about JSON Schema.

From f9d60b0e0565e73acd49c8e657093add882887ba Mon Sep 17 00:00:00 2001 From: Benjamin Granados Date: Tue, 28 May 2024 11:48:05 +0200 Subject: [PATCH 8/8] Fix linting error. --- pages/overview/faq/index.page.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pages/overview/faq/index.page.tsx b/pages/overview/faq/index.page.tsx index 220f0f7e4..19b9632fa 100644 --- a/pages/overview/faq/index.page.tsx +++ b/pages/overview/faq/index.page.tsx @@ -15,7 +15,8 @@ export default function Content() { {newTitle}

- Below you'll find answers to questions we get asked the most about JSON Schema. + Below you'll find answers to questions we get asked the most about JSON + Schema.