Skip to content

Commit 67ae796

Browse files
authored
Fixed grammar and clarity issues (#2312)
I tried making some very heavy sentences a bit more clear and change the grammar up a bit, sorry if I was a bit too picky tho. There's also a legitimate typo at the start of the docs, in case you still wanna change that. (etension -> extension)
1 parent 6964541 commit 67ae796

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

docs/local-storage.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
11
# Local Storage
22

3-
The local storage etension allows you to automatically save plain text in a storage space provided by the browser. Forget save codes! With this extension, we can make a game that doesn't require any user interaction to save progress.
3+
The local storage extension allows you to automatically save plain text in a storage space provided by the browser. Forget save codes! With this extension, we can make a game that doesn't require any user interaction to save progress.
44

55
## Namespaces
66

7-
A namespace is basically like the file in the browser's storage you want to save your codes in. Every project should use a unique namespace. If two projects use the same namespace, then they will overwrite each other's storage and they'll probably both end up broken :(
7+
A namespace is basically the file in the browser's storage you want to save your codes in. Every project should use a unique namespace. If two projects use the same namespace, they will overwrite each other's storage and they'll probably both end up broken :(
88

99
By default, the extension generates a random namespace for you and saves this inside the project, **so you shouldn't need to worry about managing the namespace yourself**. You should still be aware of what a namespace is since changing it could break your project.
1010

1111
In older versions of the extension, it was necessary to configure the namespace by running the set namespace block at the start of your project. This block should not be needed anymore unless you are doing something very advanced. For example, if you want to access variables stored in another project, you can find that project's namespace and then set your namespace to the same thing. This would let you access the values that project stored.
1212

1313
## Basic usage
1414

15-
Think of local storage as providing a special type of variable that automatically persists between sessions. Rather than using the "Make a Variable" button to make a new variable, you just type its name into an input. Unlike normal cloud variables, local storage is not restricted to just numbers.
15+
Think of local storage as providing a special type of variable that persists between sessions. Rather than using the "Make a Variable" button to make a new variable, you just type its name into an input. Unlike normal cloud variables, local storage is not restricted to just numbers.
1616

1717
To put a value into storage, use this block:
1818

@@ -88,7 +88,7 @@ The "correct" behavior to do in this type of scenario is heavily context-depende
8888

8989
## Read and write all at once
9090

91-
For projects are confident they will only be open in one window at once or that rely on manual saving where indiscriminently overwriting the old save is the expected outcome, the simplest approach is to read all values from storage into regular variables at the start, then your game does all its logic using just the regular variables. To save, your game puts these regular variabels back in storage. Here's what that looks like:
91+
For projects are confident they will only be open in one window at once, or ones that rely on manual saving where indiscriminently overwriting the old save is the expected outcome, the simplest approach is to read all values from storage into regular variables at the start, then your game does all its logic using just the regular variables. To save, your game puts these regular variabels back in storage. Here's what that looks like:
9292

9393
```scratch
9494
when i receive [start v]
@@ -129,7 +129,7 @@ Because changes to storage are always being re-read instead of being stored in a
129129
Pros:
130130

131131
* Still pretty simple.
132-
* Avoid unnecessary variable.
132+
* Avoids unnecessary variables.
133133
* Changes to storage are instantly available to all windows at the same time.
134134

135135
Cons:

0 commit comments

Comments
 (0)