Security News
Node.js EOL Versions CVE Dubbed the "Worst CVE of the Year" by Security Experts
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
china-division
Advanced tools
中华人民共和国行政区划:省份、城市、区县、乡镇(街道)
文件列表 | 格式化 | 压缩版 |
---|---|---|
省份数据 | provinces.json | provinces.min.json |
城市数据 | cities.json | cities.min.json |
区县数据 | areas.json | areas.min.json |
乡镇(街道)数据 | streets.json | streets.min.json |
“省、市” 二级联动数据 | address2.json | address2.min.json |
“省、市、区” 三级联动数据 | address3.json | address3.min.json |
“省、市、区、镇” 四级联动数据 | address4.json | address4.min.json |
注意:
由于获取数据为同步操作,出于性能考虑,不建议使用 Node 模块这种方式。
建议 下载 JSON 文件 然后在代码里使用 require 引入,原因参考 Node.js Modules。
安装:
$ npm install --save china-division
使用:
var chinaDivision = require('china-division');
// 省份数据
var provinces = chinaDivision.provinces;
// 城市数据
var cities = chinaDivision.cities;
// 区县数据
var areas = chinaDivision.areas;
// 乡镇(街道)数据
var streets = chinaDivision.streets;
// “省、市” 二级联动数据
var address2 = chinaDivision.address2;
// “省、市、区” 三级联动数据
var address3 = chinaDivision.address3;
// “省、市、区、镇” 四级联动数据
var address4 = chinaDivision.address4;
git checkout -b my-new-feature
)git commit -am 'Add some feature'
)git push origin my-new-feature
)this repo is released under the MIT License.
FAQs
The npm package china-division receives a total of 920 weekly downloads. As such, china-division popularity was classified as not popular.
We found that china-division demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.