🎨 Update addon example
This commit is contained in:
parent
06e148c2d7
commit
0a8b92893b
|
@ -22,7 +22,9 @@
|
||||||
'msvs_settings' : {
|
'msvs_settings' : {
|
||||||
'VCCLCompilerTool' : {
|
'VCCLCompilerTool' : {
|
||||||
'AdditionalOptions' : [
|
'AdditionalOptions' : [
|
||||||
'/O2','/Oy','/GL','/GF','/Gm-', '/Fm-',
|
'/O2','/Oy', # Comment this for debugging
|
||||||
|
# '/Z7', # Unomment this for debugging
|
||||||
|
'/GL','/GF','/Gm-', '/Fm-',
|
||||||
'/EHsc','/MT','/GS','/Gy','/GR-','/Gd',
|
'/EHsc','/MT','/GS','/Gy','/GR-','/Gd',
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|
|
@ -2,13 +2,14 @@
|
||||||
|
|
||||||
const util = require('util');
|
const util = require('util');
|
||||||
|
|
||||||
const { binPath } = require('addon-tools-raub').paths(__dirname);
|
const { binPath } = require('addon-tools-raub');
|
||||||
const core = require(`${binPath}/addon`);
|
|
||||||
|
const core = require(`./${binPath}/addon`);
|
||||||
|
|
||||||
|
|
||||||
const { Example } = core;
|
const { Example } = core;
|
||||||
|
|
||||||
Example.prototype[util.inspect.custom] = function() {
|
Example.prototype[util.inspect.custom] = function () {
|
||||||
return `Example { listeners: [${this.eventNames()}] }`;
|
return `Example { listeners: [${this.eventNames()}] }`;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue