Open timotheecour opened 4 years ago
jstring is a bad name IMO in case there's no consensus on this already (dont know where else to say this), JsString is better. cstring being lowercase makes more sense as it's more primitive and JsString can just be an abstraction over it.
incomplete.
string in nim js should use an ArrayBuffer, not an Array; it's typed (not dynamically typed), so it's more efficient
len
should behave same on all targets (c,vm,nimscript,js) and always return the number of bytes of UTF8 representation (consistent with current nim c, vm) refs: https://github.com/nim-lang/Nim/issues/10911given semantic differences between cstring in c and js, we should potentially introduce jstring instead
links
scratch below