Add generated typings for from.js file. (#80)

* Generate typings for from.js
* Add generated typings to files section and fix linter issue.
* Remove domexception installation from ci workflow
* Fix for .d.ts output
Co-authored-by: Jimmy Wärting <jimmy@warting.se>
This commit is contained in:
Nick K
2021-04-20 16:10:46 +02:00
committed by GitHub
parent eed6a1dddd
commit f08e6a6773
4 changed files with 6 additions and 3 deletions
-1
View File
@@ -47,7 +47,6 @@ jobs:
node-version: ${{steps.get-version.outputs.node}}
- run: npm install
- run: npm install domexception
- run: npm run report -- --colors
+1
View File
@@ -63,3 +63,4 @@ typings/
.env
index.d.ts
from.d.ts
+1
View File
@@ -1,4 +1,5 @@
const {statSync, createReadStream} = require('fs');
const Blob = require('./index.js');
const DOMException = require('domexception');
// eslint-disable-next-line unicorn/import-index
+4 -2
View File
@@ -6,14 +6,15 @@
"files": [
"from.js",
"index.js",
"index.d.ts"
"index.d.ts",
"from.d.ts"
],
"scripts": {
"lint": "xo",
"test": "xo && ava",
"report": "c8 --reporter json --reporter text ava",
"coverage": "c8 --reporter json --reporter text ava && codecov -f coverage/coverage-final.json",
"prepublishOnly": "tsc --declaration --emitDeclarationOnly --allowJs index.js"
"prepublishOnly": "tsc --declaration --emitDeclarationOnly --allowJs index.js from.js"
},
"repository": "https://github.com/node-fetch/fetch-blob.git",
"keywords": [
@@ -33,6 +34,7 @@
"ava": "^3.8.2",
"c8": "^7.2.0",
"codecov": "^3.7.0",
"domexception": "^2.0.1",
"get-stream": "^5.1.0",
"node-fetch": "^2.6.0",
"typescript": "^3.9.5",