Skip to content

Instantly share code, notes, and snippets.

@shierro
Created June 28, 2018 13:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shierro/951018d9ad123824c1f4360501e2c04f to your computer and use it in GitHub Desktop.
Save shierro/951018d9ad123824c1f4360501e2c04f to your computer and use it in GitHub Desktop.
main.js
const {
VerifySingleton,
VerifyFactory,
} = require('./verify');
const factory = new VerifyFactory();
const run = async () => {
try {
const result = await VerifySingleton.testFunc();
console.log('result', result);
const staticResult = await VerifyFactory.staticTestFunc();
console.log('result', result);
} catch (e) {
console.log('catched?', e);
}
};
run();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment