You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+7Lines changed: 7 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -40,6 +40,7 @@ The plugin needs an api key of your site and its endpoint url. Optionally you ca
40
40
To set these values you have two options:
41
41
1. Use the default module options
42
42
2. Add your options globally to the `nuxt.config.js`
43
+
3. Use environment variables
43
44
44
45
#### Module Options
45
46
When registering the module, don't register it as a string, but an array. The syntax should be:
@@ -66,6 +67,12 @@ ghost: {
66
67
}
67
68
```
68
69
70
+
#### Environment Variables
71
+
If you don't want sensitive data in your code, or got multiple environments, you can use environment variables to configure this plugin.
72
+
73
+
`GHOST_API_KEY`: Sets the api key.
74
+
`GHOST_API_URL`: Sets the api endpoint.
75
+
69
76
## Usage
70
77
The usage is pretty straight forward. This package is just a wrapper for the official [JavaScript Content API](https://ghost.org/docs/api/v3/content/). Please check out their documentation to learn about [filtering](https://ghost.org/docs/api/v3/content/#parameters) or [pagination](https://ghost.org/docs/api/v3/content/#pagination). The `filter` parameter of the following methods is an `object` representation of the available query filters.
0 commit comments