Every Brilliant Thing
Single file, ~5 KB gzipped, zero dependencies. No build step required.
。新收录的资料对此有专业解读
这句话,一下子把气氛点燃了,在X上很快就有了几万点赞和转发。
重要的是持续输出有价值的内容,积累读者信任。
If you do the above, it will of course consume your Bar(s), but since this goes over the boundary you get no help from the compiler about how you manage the JS side! The object will get freed on the Rust side, but you still have a JS handle that now points to nothing. You might say something like “so much for memory safety”, and you wouldn’t be wrong.