mirror of
				https://git.coolaj86.com/coolaj86/request.js
				synced 2025-11-03 18:42:48 +00:00 
			
		
		
		
	urequest => @coolaj86/urequest (someone just claimed it over the weekend)
This commit is contained in:
		
							parent
							
								
									a935ea7d1b
								
							
						
					
					
						commit
						fc92c66be8
					
				@ -8,8 +8,12 @@ Written from scratch.
 | 
			
		||||
 | 
			
		||||
µRequest is designed to be a drop-in replacement for request.  It supports HTTPS and follows redirects by default.
 | 
			
		||||
 | 
			
		||||
```bash
 | 
			
		||||
npm install @coolaj86/urequest
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
```js
 | 
			
		||||
var request = require('urequest');
 | 
			
		||||
var request = require('@coolaj86/urequest');
 | 
			
		||||
request('http://www.google.com', function (error, response, body) {
 | 
			
		||||
  console.log('error:', error); // Print the error if one occurred
 | 
			
		||||
  console.log('statusCode:', response && response.statusCode); // Print the response status code if a response was received
 | 
			
		||||
@ -117,7 +121,7 @@ There are at least <!--three--> two ways to debug the operation of `request`:
 | 
			
		||||
1. Launch the node process like `NODE_DEBUG=urequest node script.js`
 | 
			
		||||
   (`lib,request,otherlib` works too).
 | 
			
		||||
 | 
			
		||||
2. Set `require('urequest').debug = true` at any time (this does the same thing
 | 
			
		||||
2. Set `require('@coolaj86/urequest').debug = true` at any time (this does the same thing
 | 
			
		||||
   as #1).
 | 
			
		||||
 | 
			
		||||
<!--
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user