add node-fetch

Signed-off-by: Max Schmidt <max.schmidt@outlook.de>
This commit is contained in:
Max Schmidt 2023-05-17 18:43:20 +02:00
parent b961ec8268
commit ef3b65b1c0
2 changed files with 4 additions and 3 deletions

View File

@ -13,10 +13,11 @@
"generate:types": "cross-env PAYLOAD_CONFIG_PATH=src/payload.config.ts payload generate:types" "generate:types": "cross-env PAYLOAD_CONFIG_PATH=src/payload.config.ts payload generate:types"
}, },
"dependencies": { "dependencies": {
"payload": "^1.8.2", "cross-env": "^7.0.3",
"dotenv": "^8.2.0", "dotenv": "^8.2.0",
"express": "^4.17.1", "express": "^4.17.1",
"cross-env": "^7.0.3" "node-fetch": "^3.3.1",
"payload": "^1.8.2"
}, },
"devDependencies": { "devDependencies": {
"@types/express": "^4.17.9", "@types/express": "^4.17.9",

View File

@ -1,5 +1,5 @@
import { CollectionConfig } from "payload/types"; import { CollectionConfig } from "payload/types";
import fetch from "node-fetch";
const Posts: CollectionConfig = { const Posts: CollectionConfig = {
slug: "posts", slug: "posts",
admin: { admin: {