Hacker News new | ask | show | jobs
by zanethomas 612 days ago
Does it compile something like this into a c++ class?

makeThing(options, usethistoo) { let foo = options.foo; let thistoo = usethistoo;

  return {
    functions...
  }
}
1 comments

I'm not sure if "C++ class" is the right term, but it will certainly compile into a class behind the scenes [1]

You can use d8 to check what the class structure ends up looking like [2]

---

[1]: https://v8.dev/docs/hidden-classes

[2]: https://v8.dev/docs/d8