本文整理汇总了TypeScript中duniter/app/lib/common-libs/underscore.Underscore.extend方法的典型用法代码示例。如果您正苦于以下问题:TypeScript Underscore.extend方法的具体用法?TypeScript Underscore.extend怎么用?TypeScript Underscore.extend使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类duniter/app/lib/common-libs/underscore.Underscore
的用法示例。
在下文中一共展示了Underscore.extend方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。
示例1: async
export const prepareDuniterServer = async (options:any) => {
const catKeyring = { pub: 'HgTTJLAQ5sqfknMq7yLPZbehtuLSsKj9CxWN7k8QvYJd', sec: '51w4fEShBk1jCMauWu4mLpmDVfHksKmWcygpxriqCEZizbtERA6de4STKRkQBpxmMUwsKXRjSzuQ8ECwmqN1u2DP'};
const tacKeyring = { pub: '2LvDg21dVXvetTD9GdkPLURavLYEqP3whauvPWX4c2qc', sec: '2HuRLWgKgED1bVio1tdpeXrf7zuUszv1yPHDsDj7kcMC4rVSN9RC58ogjtKNfTbH1eFz7rn38U1PywNs3m6Q7UxE'};
const remuniterKeyring = { pub: 'DNann1Lh55eZMEDXeYt59bzHbA3NJR46DeQYCS2qQdLV', sec: '468Q1XtTq7h84NorZdWBZFJrGkB18CbmbHr9tkp9snt5GiERP7ySs3wM8myLccbAAGejgMRC9rqnXuW3iAfZACm7'};
const s1 = NewTestingServer(Underscore.extend({ pair: catKeyring }, options || {}));
const sR = NewTestingServer(Underscore.extend({ pair: remuniterKeyring }, options || {}));
const cat = {
uid: 'cat',
pub: catKeyring.pub,
sec: catKeyring.sec
}
const tac = {
uid: 'tac',
pub: tacKeyring.pub,
sec: tacKeyring.sec
}
const remuniter = {
uid: 'remuniter',
pub: remuniterKeyring.pub,
sec: remuniterKeyring.sec
}
await s1._server.initWithDAL()
await sR._server.initWithDAL()
return { s1, sR, cat, tac, remuniter };
}