How to get the link from parsing in NODEJS?

Guys I need your help.

Doing something like Parsa, below the code:

const osmosis = require('osmosis');
const fs = require('fs');
let savedData = [];
osmosis


.get('https://##########//profi')
.find('.user-preview')
.set({
 'Name': '.user-preview_name',
 'Specialization': '.user-preview_specialization',
 'City': '.user-preview_city',
 'URL': '.data-url',
})


 .data(function(data) {
console.log(data);
savedData.push(data);
})
 .done(function() {
 fs.writeFile('data.json', JSON.stringify( savedData, null, 4), function(err) {
 if(err) console.error(err);
 else console.log('Data Saved to data.json file');
})
 });


The trouble is that everything works fine, but MOST IMPORTANTLY how to get I user-contacts, ie not SHOW the CONTACTS AND most certainly a REFERENCE TO CONTACTS

<div class="user-contacts" data-component="userContacts" data-url="https://www.###########/contacts" data-component-ready="true"><a class="js-userContactsShow" href="#">Show contacts</a></div>


And not the main but same question , how to make a parser, namely ( .get('https://##########//profi') not only cling to one page and tell /profi/2 /profi/3 /profi/4
June 3rd 19 at 19:39
0 answer

Find more questions by tags Node.jsParsingnpm