This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. возраст | |
2. получаю 1 высшее | 2+ высшее | |
3. холост | есть семья | |
4. не работаю | работаю 1/2 ставки | полный раб. день | |
if работаю { | |
5. колво часов работы в день | |
6. зарплата | |
< 3M | 3M - 6M | 6M - 10M | 10M+ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function asyncThread(fn, ...args) { | |
if (!window.Worker) throw Promise.reject( | |
new ReferenceError(`WebWorkers aren't available.`) | |
); | |
const fnWorker = ` | |
self.onmessage = function(message) { | |
(${fn.toString()}) | |
.apply(null, message.data) | |
.then(result => self.postMessage(result)); |