360196c8ae
* feat: add image upload method to http client * fix: Make files optional on UploadImageResponse * fix: Fix comment typo * fix: replace loose equals with strict equals * fix: Remove useless awaits * fix: Add explicit return types to image upload helper functions * fix: Include client headers in image upload request * fix: Change type of uploadImage arg to File | Buffer instead of Blob | Buffer * doc: Add doc string * refactor: Switch to using cross-fetch instead of node-fetch v3 * chore: remove unnecessary asyncs
55 lines
1.5 KiB
JSON
55 lines
1.5 KiB
JSON
{
|
|
"name": "lemmy-js-client",
|
|
"version": "0.17.2-rc.3",
|
|
"description": "A javascript / typescript client for Lemmy",
|
|
"repository": "https://github.com/LemmyNet/lemmy-js-client",
|
|
"license": "AGPL-3.0",
|
|
"author": "Dessalines <tyhou13@gmx.com>",
|
|
"main": "./dist/index.js",
|
|
"types": "./dist/index.d.ts",
|
|
"files": [
|
|
"/dist"
|
|
],
|
|
"scripts": {
|
|
"build": "tsc",
|
|
"docs": "typedoc src/index.ts --sourcefile-url-prefix 'https://github.com/LemmyNet/lemmy-js-client/tree/main/src/'",
|
|
"lint": "tsc --noEmit && eslint --report-unused-disable-directives --ext .js,.ts,.tsx src && prettier --check src",
|
|
"prepare": "yarn run build && husky install"
|
|
},
|
|
"lint-staged": {
|
|
"*.{ts,tsx,js}": [
|
|
"prettier --write",
|
|
"eslint --fix"
|
|
],
|
|
"package.json": [
|
|
"sortpack"
|
|
]
|
|
},
|
|
"dependencies": {
|
|
"cross-fetch": "^3.1.5",
|
|
"form-data": "^4.0.0"
|
|
},
|
|
"devDependencies": {
|
|
"@types/node": "^18.6.2",
|
|
"@typescript-eslint/eslint-plugin": "^5.31.0",
|
|
"@typescript-eslint/parser": "^5.31.0",
|
|
"eslint": "^8.20.0",
|
|
"eslint-plugin-prettier": "^4.2.1",
|
|
"husky": "^8.0.1",
|
|
"lint-staged": "^13.0.3",
|
|
"prettier": "^2.7.1",
|
|
"prettier-plugin-import-sort": "^0.0.7",
|
|
"prettier-plugin-organize-imports": "^3.0.0",
|
|
"prettier-plugin-packagejson": "^2.2.18",
|
|
"sortpack": "^2.3.0",
|
|
"typedoc": "^0.21.6",
|
|
"typedoc-plugin-sourcefile-url": "^1.0.6",
|
|
"typescript": "^4.7.4"
|
|
},
|
|
"importSort": {
|
|
".js, .jsx, .ts, .tsx": {
|
|
"style": "module",
|
|
"parser": "typescript"
|
|
}
|
|
}
|
|
}
|