vue-mq icon indicating copy to clipboard operation
vue-mq copied to clipboard

Typescript support

Open juanfernandoe opened this issue 7 years ago • 9 comments

Hi,

First of all, thank you for your excellent work. Could you provide typings file in order to be able to work with typescript ?

juanfernandoe avatar May 05 '18 19:05 juanfernandoe

Thanks that's a good idea, intend to implement when I have a little time

AlexandreBonaventure avatar May 09 '18 07:05 AlexandreBonaventure

Any news on this?

avxkim avatar Sep 19 '19 16:09 avxkim

+1

juanpprieto avatar Sep 23 '19 19:09 juanpprieto

+1

AndriiKost avatar Dec 19 '19 18:12 AndriiKost

Create a file: vue-mq.d.ts

    declare module 'vue-mq' {
        import {PluginObject} from 'vue';

        interface VueMq extends PluginObject<any> {
            VueMq: VueMq;
        }

        const VueMq: VueMq;
        export default VueMq;
    }

re2005 avatar Jan 20 '20 09:01 re2005

Or an alternative for it: https://www.npmjs.com/package/vue-media-q

re2005 avatar Jan 23 '20 12:01 re2005

I only need this at present,

// declaration.d.ts

import Vue from 'vue'

declare module 'vue/types/vue' {
  interface Vue {
    $mq: 'sm' | 'md' | 'lg'  // Or keyof BreakpointRecord
  }
}

patarapolw avatar Feb 13 '20 03:02 patarapolw

Does still library provide typescript yet?? It will be really great if we have typescript version for this package.

wangxpert avatar Feb 21 '20 04:02 wangxpert

Thanks that's a good idea, intend to implement when I have a little time

@AlexandreBonaventure
Any news??

wangxpert avatar Feb 21 '20 04:02 wangxpert