Skip to content

Commit 0f3f39a

Browse files
committed
Fix JSON comments
1 parent 39caded commit 0f3f39a

File tree

6 files changed

+25
-10
lines changed

6 files changed

+25
-10
lines changed

_includes/js/objects.md

+9-3
Original file line numberDiff line numberDiff line change
@@ -144,9 +144,15 @@ gameScore.save()
144144

145145
After this code runs, you will probably be wondering if anything really happened. To make sure the data was saved, you can look at the Data Browser in your app on Parse. You should see something like this:
146146

147-
```json
148-
objectId: "xWMyZ4YEGZ", score: 1337, playerName: "Sean Plott", cheatMode: false,
149-
createdAt:"2011-06-10T18:33:42Z", updatedAt:"2011-06-10T18:33:42Z"
147+
```json5
148+
{
149+
objectId: "xWMyZ4YEGZ",
150+
score: 1337,
151+
playerName: "Sean Plott",
152+
cheatMode: false,
153+
createdAt: "2011-06-10T18:33:42Z",
154+
updatedAt: "2011-06-10T18:33:42Z"
155+
}
150156
```
151157

152158
There are two things to note here. You didn't have to configure or set up a new Class called `GameScore` before running this code. Your Parse app lazily creates this Class for you when it first encounters it.

_includes/php/objects.md

+9-3
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,15 @@ try {
3535

3636
After this code runs, you will probably be wondering if anything really happened. To make sure the data was saved, you can look at the Data Browser in your app on Parse. You should see something like this:
3737

38-
```json
39-
objectId: "xWMyZ4YEGZ", score: 1337, playerName: "Sean Plott", cheatMode: false,
40-
createdAt:"2011-06-10T18:33:42Z", updatedAt:"2011-06-10T18:33:42Z"
38+
```json5
39+
{
40+
objectId: "xWMyZ4YEGZ",
41+
score: 1337,
42+
playerName: "Sean Plott",
43+
cheatMode: false,
44+
createdAt: "2011-06-10T18:33:42Z",
45+
updatedAt: "2011-06-10T18:33:42Z"
46+
}
4147
```
4248

4349
There are two things to note here. You didn't have to configure or set up a new Class called `GameScore` before running this code. Your Parse app lazily creates this Class for you when it first encounters it.

_includes/php/setup.md

+3-1
Original file line numberDiff line numberDiff line change
@@ -62,13 +62,15 @@ Note that it is _not_ guaranteed that 'response' will be a parsable json array.
6262

6363
A couple examples of bad health responses could include an incorrect mount path, port or domain.
6464

65-
```json
65+
```json5
6666
// ParseClient::setServerURL('http://localhost:1337', 'not-good');
6767
{
6868
"status": 404,
6969
"response": "<!DOCTYPE html>...Cannot GET \/not-good\/health..."
7070
}
71+
```
7172

73+
```json5
7274
// ParseClient::setServerURL('http://__uh__oh__.com', 'parse');
7375
{
7476
"status": 0,

_includes/rest/hooks.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ and perform a `parse deploy` the usual way.
220220
To create a new function webhook post to <code class="highlighter-rouge"><span class="custom-parse-server-mount">/parse/</span>hooks/functions</code> with payload in the format
221221

222222
```json
223-
{"functionName" : x, "url" : y}
223+
{"functionName" : "baz", "url" : "https://api.example.com/baz"}
224224
```
225225

226226
Post example:

_includes/rest/users.md

+1
Original file line numberDiff line numberDiff line change
@@ -600,6 +600,7 @@ The ACL is formatted as a JSON object where the keys are either object ids or th
600600
For example, if you want the user with id `"3KmCvT7Zsb"` to have read and write access to an object, plus the object should be publicly readable, that corresponds to an ACL of:
601601

602602
```json
603+
{
603604
"ACL": {
604605
"3KmCvT7Zsb": {
605606
"read": true,

_includes/unity/objects.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ Storing data on Parse is built around the `ParseObject`. Each `ParseObject` cont
66

77
For example, let's say you're tracking high scores for a game. A single `ParseObject` could contain:
88

9-
```json
10-
score: 1337, playerName: "Sean Plott", cheatMode: false
9+
```json5
10+
{score: 1337, playerName: "Sean Plott", cheatMode: false }
1111
```
1212

1313
Keys must start with a letter, and can contain alphanumeric characters and underscores. Values can be strings, numbers, booleans, or even arrays and dictionaries - anything that can be JSON-encoded.

0 commit comments

Comments
 (0)