docs: make_your_own.md formatting fix for mkdocs (#855)

This commit is contained in:
Danny Avila 2023-08-28 14:49:26 -04:00 committed by GitHub
parent d672ac690d
commit 3574d0b823
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -177,6 +177,7 @@ If your Tool class requires more advanced initialization, you would add it to th
The default initialization can be seen in the `loadToolWithAuth` function, and most custom plugins should be initialized this way. The default initialization can be seen in the `loadToolWithAuth` function, and most custom plugins should be initialized this way.
Here are a few customConstructors, which have varying initializations Here are a few customConstructors, which have varying initializations
```javascript ```javascript
const customConstructors = { const customConstructors = {
browser: async () => { browser: async () => {
@ -196,7 +197,7 @@ Here are a few customConstructors, which have varying initializations
] ]
} }
}; };
``` ```
## Step 6: Export your Plugin into index.js ## Step 6: Export your Plugin into index.js
@ -240,7 +241,7 @@ module.exports = {
} }
] ]
}, },
``` ```
Each of the fields of the "plugin" object are important. Follow this format strictly. If your plugin requires authentication, you will add those details under `authConfig` as an array since there could be multiple authentication variables. See the Calculator plugin for an example of one that doesn't require authentication, where the authConfig is an empty array (an array is always required). Each of the fields of the "plugin" object are important. Follow this format strictly. If your plugin requires authentication, you will add those details under `authConfig` as an array since there could be multiple authentication variables. See the Calculator plugin for an example of one that doesn't require authentication, where the authConfig is an empty array (an array is always required).
@ -248,7 +249,8 @@ module.exports = {
**Note:** the `authField` prop must match the process.env variable name **Note:** the `authField` prop must match the process.env variable name
Here is an example of a plugin with more than one credential variable Here is an example of a plugin with more than one credential variable
```json
```json
[ [
{ {
"name": "Google", "name": "Google",
@ -268,7 +270,7 @@ module.exports = {
} }
] ]
}, },
``` ```
## Example: WolframAlphaAPI Tool ## Example: WolframAlphaAPI Tool