leekhub / leek-fund Goto Github PK
View Code? Open in Web Editor NEW:chart_with_upwards_trend: 韭菜盒子——VSCode 里也可以看股票 & 基金实时数据,做最好用的投资插件 🐥
Home Page: http://leek.fund
License: BSD 3-Clause "New" or "Revised" License
:chart_with_upwards_trend: 韭菜盒子——VSCode 里也可以看股票 & 基金实时数据,做最好用的投资插件 🐥
Home Page: http://leek.fund
License: BSD 3-Clause "New" or "Revised" License
例如:
https://hq.sinajs.cn/list=b_NKY
日经225代码应该为b_NKY,但是界面没有添加进来
可以使用新浪接口
这个转债是真实存在的, 但是添加的时候由于搜索不出来, 然后不允许添加, 但是直接在配置文件中添加是可以正常显示的。
用户反馈
希望可以加入基金的走势图
基金股票如果可以再进行自定义分组就好了
对于基金001691可以搜索到,可以显示走势和趋势图,但是列表显示出错
可以正常显示基金001691
在基金列表中添加新基金,搜索基金001691,添加。基金列表中显示出错。
Version: 1.48.1 (user setup)
Commit: 3dd905126b34dcd4de81fa624eb3a8cbe7485f13
Date: 2020-08-19T17:12:13.244Z (4 days ago)
Electron: 7.3.2
Chrome: 78.0.3904.130
Node.js: 12.8.1
V8: 7.8.279.23-electron.0
OS: Windows_NT x64 10.0.19041
建议将V2.0的版本迭代需求表中的<基金和股票支持置顶>功能改为自定义排序体验会更好
比如 000835 华润元大富时**A50 指数基金
版本 v1.0.0
已支持
// 配置需要监控的股票代码(新浪接口,所以去新浪找股票代码比较合适)
// 深股股,上证指数:sh000001
// 港股股票代码,如阿里巴巴:hk09988,腾讯:hk00700,美团:hk03690
// 美股指数代码,如道琼斯指数: gb_dji,纳斯达克: gb_ixic,标普500: gb_inx
// 如配置后没有数据,可以用这个链接测试一下是否有返回数据:https://hq.sinajs.cn/list=hk00700
"leek-fund.stocks": [
"sh000001",
"sh000300",
"sh000016",
"sh000688",
"sh000913",
"sh000905",
"hk03690",
"hk00700",
"hk09988",
"gb_ixic",
"gb_dji",
"gb_inx"
],
Originally posted by @giscafer in #9 (comment)
数据接口
美股:http://hq.sinajs.cn/list=usr_pdd
美股可以用这个接口的,usr_,代码里hardcode还不支持这个
走势图
美股sample:https://image.sinajs.cn/newchart/usstock/min/pdd.gif
港股sample:https://image.sinajs.cn/newchart/hk_stock/min/09988.gif
"leek-fund.funds": [
"007301",
"320007", // 原有基金代码
"161726",
"001102",
"003885",
"001071",
"005963",
"002316",
"007776",
"161028",
"001632",
"007874",
"004857",
"161725",
"420009",
"377240",
"320022",
"001595",
"161723",
null, // 无故多处的null 值
"005760",
"320007" // 还能新增同样代码
],
现在只能看到小数点后两位,从而导致百分比的计算也有问题
我今天早上看到另一个仓库的stock-watch。
https://github.com/TDGarden/stock-watch
你们的代码很类似,别人是2年前的项目了,请问是借鉴吗?
如果不是建议优化。
状态栏里面 3个企鹅 +1个折线,能换成一个LOGO吗?占的地方有点多
周六晚上8点还在发请求
周六晚上8点,断网后,重载vscode窗口,接口一直在请求,然后报错
港股的价格不对
插件版本:1.2.5
vscode:1.48.0
基金栏折叠会导致股票栏数据停止更新
提供给用户快速设置一些配置,增强使用体验和便利性
Setting View 默认是折叠收起的。
基金的可以走
http://fundgz.1234567.com.cn/js/320007.js?callback=a
股票的走
https://hq.sinajs.cn/list=hk00700,rt_hk03690
欢迎PR
股票:
A股:9:30--15:00
港股:9:30--16:00
美股:21:30--4:00(夏令时)、22:30--5:00(冬令时) 取并集 21:30--5:00
其他:暂时与美股时间相同
基金:
由于美股/港股基金相对A股基金较少,暂时采用A股9:30--15:00策略
todo by @httpcheck
投资其实就是一次心态修炼,稳住心态长期投资都会有收益的!!
今年开始学习养基,有一天想安装个 VSCode 插件,但没找到好用的 VSCode 基金插件,插件中大部分只有股票的功能,所以就决定开发韭菜盒子了……
v1.40.0+
韭菜盒子
→ install即可韭菜盒子
→ uninstall → install即可本插件具有以下特点:
排序、降序按涨跌值排序;不排序的模式是按基金代码或股票代码的顺序,配置文件中数组的元素顺序(可以临时利用这个调整你们想置顶关注的股票或基金)
v1.3.0
添加/删除股票或基金时,建议使用新增按钮模糊搜索添加(支持名称和编码搜索),详细可查看 韭菜盒子使用文档
下面是插件配置说明:
"configuration": {
"properties": {
// 配置需要监控的股票代码(新浪接口,所以去新浪找股票代码比较合适)
// 深股股,上证指数:sh000001
// 港股股票代码,如阿里巴巴:hk09988,腾讯:hk00700,美团:hk03690
// 美股指数代码,如道琼斯指数: usr_dji,纳斯达克: usr_ixic,标普500: usr_inx
// 如配置后没有数据,可以用这个链接测试一下是否有返回数据:https://hq.sinajs.cn/list=hk00700
"leek-fund.stocks": {
"type": "array",
"default": [
"sh000001",
"sh000300",
"sh000016",
"sh000688",
"hk03690",
"hk00700",
"usr_ixic",
"usr_dji",
"usr_inx"
],
"description": "配置需要监控的股票代码(建议通过界面新增)"
},
// 配置需要监控的基金代码
"leek-fund.funds": {
"type": "array",
"default": [
"001632",
"420009",
"320007",
"003096",
"001102",
"003885",
"001071",
"005963"
],
"description": "配置需要监控的基金代码(建议通过界面新增)"
},
"leek-fund.statusBarStock": {
"type": "array",
"default": [
"sh000001"
],
"description": "状态栏展示的股票(建议通过界面选择设置,必须是在股票代码已设置存在)"
},
"leek-fund.interval": {
"type": "number",
"default": 5000,
"description": "配置轮询请求最新数据的时间间隔,单位:毫秒(最小轮询间隔是3秒)"
},
"leek-fund.riseColor": {
"type": "string",
"default": "white",
"description": "股票涨的颜色"
},
"leek-fund.fallColor": {
"type": "string",
"default": "#C9AD06",
"description": "股票跌的颜色"
}
}
}
问题会逐渐修复和完善
如遇页面操作无法解决的问题,可点击左下角齿轮 setting 搜 韭菜盒子
可进入配置文件进行修改
如遇添加基金后,显示基金名称为 Null
请先验证下 http://fundgz.1234567.com.cn/js/xxxxx.js?callback=a
行的话但是插件显示 null
麻烦进行群反馈问题,不行就是接口不支持,解决不了,除非有新接口。
如遇股票面板无数据
,可先检查下是否开启代理。股票走https。关闭代码刷新数据重试。如果仍无数据,麻烦进行群反馈问题
如果出现此错误,浏览器打开报错链接,自测链接是否请求通,如果浏览器可以,VSCode不行,检查一下是不是VSCode走了代理导致网络不通?
使用有 bug 或者体验问题可以在 issues 反馈:https://github.com/giscafer/leek-fund/issues
自行添加基金持有份额,估算当前收益及亏损
RT
`{
"C_Cpp.updateChannel": "Insiders",
"leek-fund.stocks": [
"0000001",
"0000300",
"0000016",
"0000688",
"0399006",
"0000913",
"0000905",
"0399975",
"0399995",
"0300666",
"0300003"
]
}`
用得代码接口港股的数据还在4月份。
https://api.money.126.net/data/feed/hk03690?callback=a
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.