Skip to content

Commit c058746

Browse files
committed
updated documentation
1 parent 599751c commit c058746

File tree

2 files changed

+10
-13
lines changed

2 files changed

+10
-13
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ Bun installation:
3636
```javascript
3737
import { STEVE } from '@codingap/steve';
3838

39-
STEVE.render('Hello <steve> return Steve.data.name; </steve>!', { name: 'STEVE' });
39+
STEVE.render('Hello <steve> return steve.data.name; </steve>!', { name: 'STEVE' });
4040
```
4141

4242
Output:

documentation.md

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# STEVE
22

3-
### Last Modified: 11/23/2023
3+
### Last Modified: 11/18/2024
44

55
## Template Engine:
66
Any file can be processed by `STEVE`. All it uses is `<steve> // javascript code here </steve>` to create a block that can be ran. Anything returned will be rendered. For example...
@@ -27,23 +27,23 @@ Any file can be processed by `STEVE`. All it uses is `<steve> // javascript code
2727
</ul>
2828
```
2929

30-
These JavaScript blocks also have access to a global `STEVE` object that includes some methods to add outside code in the file. The `STEVE` object has these methods/variables:
30+
These JavaScript blocks also have access to a global `steve` object that includes some methods to add outside code in the file. The `steve` object has these methods/variables:
3131
- `data`: The data provided from the function who is rendering the file
3232
- `include(file, data)`: Loads the file from the `includeDirectory` with the data provided.
3333

34-
To create a engine, use the `STEVE` object in NodeJS...
34+
To create a engine, use the `STEVE` object...
3535

3636
Example:
3737

3838
`template.steve`
3939
```html
40-
<h1>Hello <steve> return STEVE.data.name; </steve>!</h1>
41-
<p>Your number squared is <steve> return Math.pow(STEVE.data.number, 2); </steve>!</p>
40+
<h1>Hello <steve> return steve.data.name; </steve>!</h1>
41+
<p>Your number squared is <steve> return Math.pow(steve.data.number, 2); </steve>!</p>
4242
```
4343

4444
`index.js`
4545
```javascript
46-
import { STEVE } from 'steve';
46+
import { STEVE } from '@codingap/steve';
4747

4848
STEVE.renderFile('./template.steve', { number: 123, name: 'AP' });
4949
```
@@ -70,7 +70,7 @@ You can also modify how `STEVE` reads and compiles files as well. Such settings
7070
```javascript
7171
STEVE.tags = { start: ..., end: ... }
7272
```
73-
- Name of the global `STEVE` object (current defaults to `Steve`)
73+
- Name of the global `STEVE` object (current defaults to `steve`)
7474
- To modify, use this code...
7575
```javascript
7676
STEVE.globalName = ...;
@@ -119,7 +119,7 @@ STEVE.activePlugin = 'EXAMPLE2';
119119
...
120120
```
121121
122-
Sometimes, you might want to add NodeJS modules into a `STEVEPlugin`. By default, there are no modules, but you can add modules to be used in the `augment` using the `globalModules` variable. Just add a module by using it like an object. For example...
122+
Sometimes, you might want to add modules into a `STEVEPlugin`. By default, there are no modules, but you can add modules to be used in the `augment` using the `globalModules` variable. Just add a module by using it like an object. For example...
123123
124124
```javascript
125125
...
@@ -334,7 +334,4 @@ Here are the options for a `Generator`:
334334
- `isFile`: boolean to determine whether `render` is a path or raw string
335335
- `generator`: List of files to be generated
336336
- `name`: Name of the route
337-
- `data`: Data specific to the generated files
338-
339-
## ExpressJS Support
340-
Not implemented yet!
337+
- `data`: Data specific to the generated files

0 commit comments

Comments
 (0)