Skip to content

Commit

Permalink
Replace typings with @types (#106)
Browse files Browse the repository at this point in the history
  • Loading branch information
cprecioso authored and blakeembrey committed May 22, 2018
1 parent b66670a commit 10d7bcd
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 36 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,4 @@ coverage/
node_modules/
npm-debug.log
dist/
typings/
popsicle.js
14 changes: 1 addition & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -409,19 +409,7 @@ This module is designed for ES5 environments, but requires two ES2015 polyfills

## TypeScript

This project is written using [TypeScript](https://github.com/Microsoft/TypeScript) and [typings](https://github.com/typings/typings). Since version `1.3.1`, you can install the type definition using `typings`.

```
typings install npm:popsicle --save
```

Note that for a brand new project you might need to add the definition for node via the following command:

```
typings install env~node --save --global
```

Make sure you add `typings/index.d.ts` to your TypeScript project (using `files` or `includes` in `tsconfig.json`) if it isn't already.
This project is written using [TypeScript](https://github.com/Microsoft/TypeScript) and publishes the typings to NPM alongside the package.

## Development

Expand Down
12 changes: 8 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
"version": "9.2.0",
"description": "Simple HTTP requests for node and the browser",
"main": "dist/common.js",
"types": "dist/common.d.ts",
"files": [
"dist/",
"typings.json",
"LICENSE",
"logo.svg"
],
Expand All @@ -27,7 +27,7 @@
"test-server-open": "PORT=7357 node scripts/server.js & echo $! > server.pid; HTTPS_PORT=7358 node scripts/https-server.js & echo $! > https-server.pid",
"test-server-close": "if [ -f server.pid ]; then kill -9 $(cat server.pid); rm server.pid; fi; if [ -f https-server.pid ]; then kill -9 $(cat https-server.pid); rm https-server.pid; fi",
"test": "npm run lint && npm run build && npm run test-server-open && npm run test-cov && npm run test-browser; EXIT=$?; npm run test-server-close; exit $EXIT",
"prepublish": "typings install && npm run build"
"prepublish": "npm run build"
},
"repository": {
"type": "git",
Expand All @@ -53,6 +53,7 @@
},
"homepage": "https://github.com/blakeembrey/popsicle",
"devDependencies": {
"@types/blue-tape": "^0.1.30",
"@types/node": "^8.0.0",
"blue-tape": "^1.0.0",
"bluebird": "^3.0.5",
Expand All @@ -66,10 +67,13 @@
"tape-run": "3.0.0",
"tslint": "^5.2.0",
"tslint-config-standard": "^7.0.0",
"typescript": "^2.4.1",
"typings": "^2.0.0"
"typescript": "^2.4.1"
},
"dependencies": {
"@types/concat-stream": "^1.6.0",
"@types/form-data": "0.0.33",
"@types/methods": "^1.1.0",
"@types/tough-cookie": "^2.3.0",
"concat-stream": "^1.4.7",
"form-data": "^2.0.0",
"make-error-cause": "^1.2.1",
Expand Down
7 changes: 1 addition & 6 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,5 @@
"removeComments": true,
"sourceMap": true,
"inlineSources": true
},
"include": [
"src/**/*",
"custom_typings/**/*",
"typings/**/*"
]
}
}
12 changes: 0 additions & 12 deletions typings.json

This file was deleted.

0 comments on commit 10d7bcd

Please sign in to comment.