Can't get Search and Sort on same Page

I managed to add a basic Sort like this:


        <button class="sort">Sort</button>

            {{#each cvs}}
                    {{> Interviu}}


Template.Interviuri.onCreated(function () {
    var self = this
    self.autorun(function () {
        self.sortOrder = new ReactiveVar(-1)

    cvs() {
        const instance = Template.instance()
           return Cvs.find({}, { sort: { createdAt: instance.sortOrder.get() } })
    'click .sort'(event, instance) {
        instance.sortOrder.set(instance.sortOrder.get() * -1)

Next i wanted to implement Search on the same page. So the best way i could found was EasySearch.
But using EasySearch, it means i must change the way my items are being displayed. And this means the sort doesn’t work anymore.


        <div class="searchBox pull-right">
            {{> EasySearch.Input index=cvsIndex attributes=searchAttributes }}

            {{#EasySearch.Each index=cvsIndex }}
                {{> Interviu}}


CvsIndex = new EasySearch.Index({
    collection: Cvs,
    fields: ['name'],
    engine: new EasySearch.Minimongo()



    cvsIndex: () => CvsIndex,

How can i have both search and sort working at the same time?
Please help, i’m stuck on this for days.