microlink logo

Microlink Recipe for Meetup

meetup.js
const mql = require('@microlink/mql')

const meetup = async (url, opts) =>
  mql(url, {
    data: {
      members: {
        selector: '.groupHomeHeaderInfo-memberLink span',
        type: 'text',
      },
      pastEvents: {
        selectorAll: '.eventCard',
        attr: {
          title: {
            selector: '.eventCardHead--title',
          },
          link: {
            selector: '.eventCard--link',
            attr: 'href',
            type: 'url',
          },
          attendees: {
            selector: '.avatarRow--attendingCount span',
          },
        },
      },
    },
    ...opts,
  })

const result = await meetup('https://www.meetup.com/Alicante-Frontend/')
console.log(result)