How to create a symlink within browserFS

左心房为你撑大大i 提交于 2020-01-06 08:08:20

问题


I'm trying to create a symlink inside of BrowserFS.

I can confirm that BrowserFS can read sym links just fine... (I tested by making a zip file and loading it in, and doing fs.readFile and all is A-OK)

However, when I try to create a sym link via fs.symlink, I get an Error, I assume this is meaning it is not supported.

Can any of the folks out there that may use browserFS know how to propertly create, or any workarounds for creating symlinks?

One idea is to create the contents of a symlink and set file modes, but I had a hard time finding the exact way to do that. Any help appreciated!

I've included a codesandbox in case anyone is interested! https://codesandbox.io/s/43wroyjy9w

来源:https://stackoverflow.com/questions/55131565/how-to-create-a-symlink-within-browserfs

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!