Skip to content

Commit b847539

Browse files
authored
Update readme.md
1 parent c76ea4f commit b847539

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

readme.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ autoload.include("folder.File"); // throws no exception when file is missing.
285285
```
286286

287287
### Loading other JS files
288-
The later sections will explain how to load the various types of files. However, if you want to load any other type of file, provided you have configured the root director of the `autoload` object, use the below code.
288+
The later sections will explain how to load the various types of files. However, if you want to load any other type of file, provided you have configured the root directory of the `autoload` object, use the below code.
289289
```javascript
290290
// folder structure
291291
|root
@@ -306,7 +306,7 @@ let Utility = new js.classes.Utility();
306306
```
307307
# UI
308308
## OSM - OpenScript Markup
309-
OSM allows you to write markup using javascript method. In OJS, there is an object called `h` representing the `MarkupEngine`. You can create any element using this object similar to HTML. Just like HTML in the browser, OSM is element agnostic.
309+
OSM allows you to write markup using Javascript method. In OJS, there is an object called `h` representing the `MarkupEngine`. You can create any element using this object similar to HTML. Just like HTML in the browser, OSM is element agnostic.
310310

311311
### Syntax
312312
```javascript
@@ -324,7 +324,7 @@ h.$anSVGElement(
324324

325325
```
326326
* To create an element, use `h.elementName()`.
327-
* Attributes are key-value pairs passed to the element in objects. Replace every dash with underscore in the attribute names.
327+
* Attributes are key-value pairs passed to the element in objects. Replace every dash with an underscore in the attribute names.
328328
* Add children to the element following the above guide. Note that you can also pass an array of children and attributes to an element.
329329

330330
### OSM Example
@@ -346,13 +346,13 @@ h.div(
346346

347347
```
348348
### Special Attributes
349-
Some attributes are special and tells OJS Markup engine to perform specific actions when rendering.
349+
Some attributes are special and tell OJS Markup engine to perform specific actions when rendering.
350350

351351
| Attribute | Value | Function |
352352
|-----------|-------|----------|
353353
| parent | HTML Element| appends the rendered OSM to the parent element.|
354354
| resetParent| boolean| tells OJS to replace the elements in the parent with the rendered OSM.|
355-
| replaceParent | boolean | tells OJS to replace parent element completely with the rendered OSM |
355+
| replaceParent | boolean | tells OJS to replace the parent element completely with the rendered OSM |
356356
| firstOfParent | boolean | tells OJS to place the rendered OSM as the first child of the parent element|
357357
| c_attr | object of attributes | used as attributes for the wrapper element of a rendered OSM component|
358358
| listeners | object of event-callback pairs | equivalent to `element.addEventListener(event, callback)`|
@@ -456,7 +456,7 @@ h.button(
456456
```
457457
>Components address this using the `this.method(...args)` or `this.xMethod(...args)` methods. This will be shown under the components section.
458458
459-
#### Escaping Formatting
459+
#### Escape Formats
460460
The arguments will be formatted such that they are parsable when placed in the `HTML` markup. for example:
461461
- strings will have quotations around them,
462462
- number will have no quotations

0 commit comments

Comments
 (0)