nodejs的安装
| https://nodejs.org/en/ |
| # 命令行运行 node+js 文件名 |
| # 在pycharm中安装插件 Node.js后就可以一直run运行啦 |

插件

python如何调用js
| pyexjs |
| # 安装命令:pip install pyexecjs2 |
| import execjs |
| print(execjs.get().name) |
| # 运行结果:Node.js (V8),如果不显示Node.js (V8),有可能是path环境变量加载有问题,重启pycharm大概率可以解决 |
| # 如何使用: |
| #在使用python调用之前,一定要在js文件里调通它。 |
| #如果你已在js文件里调通了,那么请将你的测试代码干掉。防止出现一些特殊的逻辑问题... |
| with open("xxx.js","r",encoding="utf-8")as f: |
| js =f.read() |
| obj = execjs.compile(js) |
| result = obj.call("函数名",参数) |

浏览器工具的使用
找到加密入口的方法
更换npm为国内的镜像
| #npm官方库搜索: https: |
| #JS语法规则:https: |
| |
| #rsa.js很古老的一个库 https: |
1.首先打开我的电脑,找到C盘中用户得出文件夹,找到你当前正在使用的用户


| registry=http://registry.npmmirror.com/ |
| |
| disturl=https://registry.npmmirror.com/-/binary/node/ |
| |
| sass_binary_site=https://registry.npmmirror.com/-/binary/node-sass |
| |
| sharp_libvips_binary_host=https://registry.npmmirror.com/-/binary/sharp-libvips |
| python_mirror=https://registry.npmmirror.com/-/binary/python/ |
| electron_mirror=https://registry.npmmirror.com/-/binary/electron/ |
| electron_builder_binaries_mirror=https://registry.npmmirror.com/-/binary/electron-builder-binaries/ |
| |
| canvas_binary_host_mirror=https://registry.npmmirror.com/-/binary/canvas |
| node_sqlite3_binary_host_mirror=https://registry.npmmirror.com/-/binary/sqlite3 |
| better_sqlite3_binary_host_mirror=https://registry.npmmirror.com/-/binary/better-sqlite3 |
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 分享一个免费、快速、无限量使用的满血 DeepSeek R1 模型,支持深度思考和联网搜索!
· 基于 Docker 搭建 FRP 内网穿透开源项目(很简单哒)
· ollama系列01:轻松3步本地部署deepseek,普通电脑可用
· 25岁的心里话
· 按钮权限的设计及实现