import ContactMock from '../static/api/mock/ContactMock.js'
    export default class ContactService {
    static list() {
        var query = ` query { 
            contacts{
                id
                name
                surname
                email
                imagesrc
                homepage
                description
            }
        }`
        console.log(ContactMock.get(query))
        var list = ContactMock.get(query)['data']['contacts']

        return list
    }
    static get(contactId) {
        var query = ` query { 
            contacts{
                id
                name
                surname
                email
                imagesrc
                homepage
                description
            }
        }`
        console.log(ContactMock.get(query))
        var list = ContactMock.get(query)['data']['contacts'].filter(function (contact) {
  return contact.id == contactId
})
        return list[0]
    }
} 