hooks
hooks copied to clipboard
调试模式下 useContext<Context>() 获取值为undefined
调试模式下 useContext<Context>() 获取值为undefined
vue-faas 示例项目
就是这个模板,换了好几个nodejs版本,windows和linux环境下都是这样
https://user-images.githubusercontent.com/32608524/174499929-5e477648-fc35-485d-810a-e5de7cf3da26.png
调用入口是哪儿

https://github.com/midwayjs/hooks/tree/main/examples/vue-faas
一样的问题
Node.js v18 中 v8 的 BUG,升级至 v18.9.0 即可解决。
https://github.com/nodejs/node/issues/43148