From 78012dd20ca592ef342f44ff5ad2af6f5fc31a64 Mon Sep 17 00:00:00 2001 From: Ryan Brainard Date: Tue, 27 Nov 2018 13:44:28 +0900 Subject: [PATCH 1/2] Publish Types - Move `index.d.ts` into `src`, next to `index.js` - At build time, move `index.d.ts` to `lib`, next to the transpiled `index.js` - Register `./lib/index.d.ts` as main type file in `package.json` --- package.json | 3 ++- index.d.ts => src/index.d.ts | 0 2 files changed, 2 insertions(+), 1 deletion(-) rename index.d.ts => src/index.d.ts (100%) diff --git a/package.json b/package.json index c81f763..4746910 100644 --- a/package.json +++ b/package.json @@ -3,8 +3,9 @@ "version": "2.0.1", "description": "A simple, declarative, and composable way to fetch data for React components.", "main": "./lib/index.js", + "types": "./lib/index.d.ts", "scripts": { - "build": "babel src --out-dir lib", + "build": "babel src --out-dir lib; cp src/*.d.ts lib", "clean": "rimraf lib dist coverage", "lint": "eslint src test", "prepublish": "npm run clean && npm run lint && npm run build", diff --git a/index.d.ts b/src/index.d.ts similarity index 100% rename from index.d.ts rename to src/index.d.ts From d4421f4c6fa73111067b500728166c016b6704c2 Mon Sep 17 00:00:00 2001 From: Ryan Brainard Date: Tue, 27 Nov 2018 13:48:55 +0900 Subject: [PATCH 2/2] 2.0.2-0 --- npm-shrinkwrap.json | 2 +- package.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index 6c8cf84..0760165 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -1,6 +1,6 @@ { "name": "react-refetch", - "version": "2.0.1", + "version": "2.0.2-0", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 4746910..8ff47f9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-refetch", - "version": "2.0.1", + "version": "2.0.2-0", "description": "A simple, declarative, and composable way to fetch data for React components.", "main": "./lib/index.js", "types": "./lib/index.d.ts",