wasm-bindgen/examples/import_js/defined-in-js.js
2018-05-23 12:14:12 -07:00

22 lines
276 B
JavaScript

export function name() {
return 'World';
}
export class MyClass {
constructor() {
this._number = 42;
}
get number() {
return this._number;
}
set number(n) {
return this._number = n;
}
render() {
return `My number is: ${this.number}`;
}
}