New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@imaegoo/node-ip2region

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@imaegoo/node-ip2region - npm Package Compare versions

Comparing version 2.1.0 to 2.1.1

15

package.json
{
"name": "@imaegoo/node-ip2region",
"version": "2.1.0",
"description": "ip database ",
"version": "2.1.1",
"description": "unofficial nodejs client of ip2region",
"main": "ip2region.js",

@@ -13,3 +13,3 @@ "scripts": {

"type": "git",
"url": "https://github.com/lionsoul2016/ip2region"
"url": "https://github.com/imaegoo/ip2region"
},

@@ -24,9 +24,12 @@ "keywords": [

"bugs": {
"url": "https://github.com/lionsoul2016/ip2region/issues"
"url": "https://github.com/lionsoul2014/ip2region/issues"
},
"homepage": "https://github.com/lionsoul2016/ip2region",
"homepage": "https://github.com/imaegoo/ip2region",
"devDependencies": {
"jest": "^19.0.2",
"benchmark": "^2.1.4"
},
"engines": {
"node" : ">=6.0.0"
}
}
}

22

README.md
# nodejs 客户端
非官方维护的 ip2region
## Install
**node 版本 : >= 6.0.0**
```
npm install lionsoul-ip2region --save
npm install @imaegoo/node-ip2region --save
```
## 已测试通过的 node 版本列表
```
6.0.0
6.11.2
8.0.0
10.0.0
12.0.0
```
## Example
```
const searcher = require('lionsoul-ip2region').create();
const searcher = require('@imaegoo/node-ip2region').create();
searcher.btreeSearchSync('xxx.xxx.xxx.xxx')

@@ -86,2 +102,2 @@ // => { city: 2163, region: '中国|0|广东省|深圳市|联通' }

6 BinarySearch 6.497
```
```
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc