Skip to content

Commit 872e860

Browse files
Merge pull request #35 from open-olive/examples-update
update NodeJS examples to include relevant command
2 parents 1eb18c6 + c56a5d8 commit 872e860

File tree

5 files changed

+133
-0
lines changed

5 files changed

+133
-0
lines changed

ldk/node/examples/clipboard/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"description": "",
55
"main": "src/index.ts",
66
"scripts": {
7+
"build": "rm -rf dist && tsc",
78
"test": "echo \"Error: no test specified\" && exit 1"
89
},
910
"author": "",
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
## Clipboard LDK Usage Example
2+
This NodeJS module utilizes the OliveHelps NodeJS LDK to demonstrate listening for clipboard events and sending them to the OliveHelps UI as Whispers.
3+
4+
### Modifying
5+
The Loop itself is defined in `src/index.ts`
6+
7+
Install dependencies
8+
```shell
9+
npm install
10+
```
11+
12+
Modify `src/index.ts` as desired.
13+
14+
### Running Locally
15+
16+
#### Local Plugin Command (Recommended)
17+
18+
Olive Helps lets you add a local command as a Local Loop:
19+
20+
1. Open Olive Helps.
21+
2. Open the Loop Library:
22+
1. Click the Hamburger icon.
23+
2. Click Loop Library.
24+
3. Click the "Install Local Loop" button:
25+
4. Select the working directory for the Loop (the directory this README is in).
26+
5. Enter the command to be executed, including any arguments. For this example the command will be `./node_modules/.bin/ts-node src/index.ts`
27+
6. Click Install.
28+
29+
The command will be installed as a Loop. If you need to change the command or its arguments you'll need remove it and then add the new commands.
30+
31+
Otherwise, if you instead want to make changes to the Loop itself, you can:
32+
- Modify `src/index.ts`
33+
- Restart OliveHelps
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
## Network LDK Usage Example
2+
This NodeJS module utilizes the OliveHelps NodeJS LDK to demonstrate the usage of the Network sensor
3+
4+
### Modifying
5+
The Loop itself is defined in `src/index.ts`
6+
7+
Install dependencies
8+
```shell
9+
npm install
10+
```
11+
12+
Modify `src/index.ts` as desired.
13+
14+
### Running Locally
15+
16+
#### Local Plugin Command (Recommended)
17+
18+
Olive Helps lets you add a local command as a Local Loop:
19+
20+
1. Open Olive Helps.
21+
2. Open the Loop Library:
22+
1. Click the Hamburger icon.
23+
2. Click Loop Library.
24+
3. Click the "Install Local Loop" button:
25+
4. Select the working directory for the Loop (the directory this README is in).
26+
5. Enter the command to be executed, including any arguments. For this example the command will be `./node_modules/.bin/ts-node src/index.ts`
27+
6. Click Install.
28+
29+
The command will be installed as a Loop. If you need to change the command or its arguments you'll need remove it and then add the new commands.
30+
31+
Otherwise, if you instead want to make changes to the Loop itself, you can:
32+
- Modify `src/index.ts`
33+
- Restart OliveHelps
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
## Whisper Disambiguation LDK Usage Example
2+
This NodeJS module utilizes the OliveHelps NodeJS LDK to demonstrate the usage of Whisper Disambiguation.
3+
4+
### Modifying
5+
The Loop itself is defined in `src/index.ts`
6+
7+
Install dependencies
8+
```shell
9+
npm install
10+
```
11+
12+
Modify `src/index.ts` as desired.
13+
14+
### Running Locally
15+
16+
#### Local Plugin Command (Recommended)
17+
18+
Olive Helps lets you add a local command as a Local Loop:
19+
20+
1. Open Olive Helps.
21+
2. Open the Loop Library:
22+
1. Click the Hamburger icon.
23+
2. Click Loop Library.
24+
3. Click the "Install Local Loop" button:
25+
4. Select the working directory for the Loop (the directory this README is in).
26+
5. Enter the command to be executed, including any arguments. For this example the command will be `./node_modules/.bin/ts-node src/index.ts`
27+
6. Click Install.
28+
29+
The command will be installed as a Loop. If you need to change the command or its arguments you'll need remove it and then add the new commands.
30+
31+
Otherwise, if you instead want to make changes to the Loop itself, you can:
32+
- Modify `src/index.ts`
33+
- Restart OliveHelps
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
## Whisper List LDK Usage Example
2+
This NodeJS module utilizes the OliveHelps NodeJS LDK to demonstrate the different types of formatting and options available in Loop Whispers.
3+
4+
### Modifying
5+
The Loop itself is defined in `src/index.ts`
6+
7+
Install dependencies
8+
```shell
9+
npm install
10+
```
11+
12+
Modify `src/index.ts` as desired.
13+
14+
### Running Locally
15+
16+
#### Local Plugin Command (Recommended)
17+
18+
Olive Helps lets you add a local command as a Local Loop:
19+
20+
1. Open Olive Helps.
21+
2. Open the Loop Library:
22+
1. Click the Hamburger icon.
23+
2. Click Loop Library.
24+
3. Click the "Install Local Loop" button:
25+
4. Select the working directory for the Loop (the directory this README is in).
26+
5. Enter the command to be executed, including any arguments. For this example the command will be `./node_modules/.bin/ts-node src/index.ts`
27+
6. Click Install.
28+
29+
The command will be installed as a Loop. If you need to change the command or its arguments you'll need remove it and then add the new commands.
30+
31+
Otherwise, if you instead want to make changes to the Loop itself, you can:
32+
- Modify `src/index.ts`
33+
- Restart OliveHelps

0 commit comments

Comments
 (0)