Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

想在web端调用json文件配置可以怎么做? #22

Open
Tracker647 opened this issue Dec 10, 2024 · 3 comments
Open

想在web端调用json文件配置可以怎么做? #22

Tracker647 opened this issue Dec 10, 2024 · 3 comments

Comments

@Tracker647
Copy link

比如Cwebsocket的例子,我不想写死,我想用一个json文件保存连接的ip地址,程序启动时读取这个json来连接,但是不清楚awtk-web里对文件读取怎么处理?机器上能正常读取的逻辑到了web就没用了。

@xianjimli
Copy link
Member

@Tracker647
Copy link
Author

Tracker647 commented Dec 22, 2024

这个感觉是一次读取然后写到awtk_asm.js里的,属于一次写死,在web项目里对对于json的二次修改就不会读取。有无办法让项目启动后能再读取更新后的内容?

@xianjimli
Copy link
Member

网络是异步接口,文件系统是同步接口,两者没法统一。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants