
Security News
/Research
Wallet-Draining npm Package Impersonates Nodemailer to Hijack Crypto Transactions
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
@esmjs/geo
中国地理信息(GeoJSON)
rust
爬虫: 使用rust
现代系统编程语言编写爬虫来获取中国地理信息,安全性高、速度快并且并发性高esbuild
打包,本质使用go
语言打包,拥有极快的打包速度Tree-shaking
,只对引入的代码进行打包Dependencies
依赖,只会安装项目本身TypeScript
编写,拥有强大的类型推导提示# npm
npm install @esmjs/geo
# or yarn
yarn add @esmjs/geo
# or pnpm
pnpm add @esmjs/geo
// 如搭配 ECharts 地图组件,@esmjs/geo 还支持中国全省数据,请看下面的速查表
// import { china as geoChina } from "@esmjs/geo"; // 如有命名冲突使用 as 别名即可
import { china } from "@esmjs/geo";
import * as echarts from "echarts/core";
/**
* 由于 echarts 没有导出 geoJSON 的 GeoJSONSourceInput 类型
* china 只能导出标准的 GeoJSON 格式类型
* 如果你的项目是 TypeScript 编写,下面代码加上 //@ts-expect-error 即可
*/
echarts.registerMap("china", { geoJSON: china });
常用于 ECharts 地图组件
一个中国,34
个省级行政区,23
个省、5
个自治区、4
个直辖市、2
个特别行政区
中国 | 陕西 | 山西 | 辽宁 | 吉林 | 黑龙江 |
---|---|---|---|---|---|
china | shaanxi | shanxi | liaoning | jilin | heilongjiang |
江苏 | 浙江 | 安徽 | 福建 | 江西 | 山东 |
jiangsu | zhejiang | anhui | fujian | jiangxi | shandong |
河南 | 湖北 | 湖南 | 广东 | 海南 | 四川 |
henan | hubei | hunan | guangdong | hainan | sichuan |
贵州 | 云南 | 河北 | 甘肃 | 青海 | 台湾 |
guizhou | yunnan | hebei | gansu | qinghai | taiwan |
广西 | 内蒙古 | 西藏 | 宁夏 | 新疆 | 北京 |
guangxi | neimenggu | xizang | ningxia | xinjiang | beijing |
天津 | 上海 | 重庆 | 香港 | 澳门 | |
tianjin | shanghai | chongqing | hongkong | aomen |
rust
编写爬虫程序esbuild
打包而不是rollup
esm
包,为什么package.json
文件还要加main
、module
、types
配置rust
爬虫程序rust
相关学习资料npmjs
的rust
包管理器rust
安装环境麻烦,如何通过docker
运行rust
爬虫程序1.0.0 (2023-12-01)
rust
方面:支持爬取全国各省数据;代码全量抽离,方便二次开发;优化打印信息;使用 path_abs 处理路径,支持跨平台系统;类型补全
typescript
和 @esmjs/geo 功能方面:导出中国和全省数据,支持下钻到省,在地图上显示某省的市;添加 速查表,方便使用者查阅;常见问题和相关知识查阅 FAQ
FAQs
中国地理信息(GeoJSON)
We found that @esmjs/geo 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
/Research
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
Security News
/Research
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.