Git Product home page Git Product logo

Comments (4)

foxbenjaminfox avatar foxbenjaminfox commented on August 30, 2024 1

Thanks for pointing that out. It seems that I made a mistake, and forgot to add the types directory to the list of published directories in v3.8.0. I've released a v3.8.1 release which fixes this.

Please let me know if it works for you properly now.

from vue-async-computed.

nwtgck avatar nwtgck commented on August 30, 2024 1

@foxbenjaminfox Thank you very much. It seems the type definition problem was fixed.

I'm not sure the correct usage in TypeScript. I imported like the following.
import AsyncComputed from "vue-async-computed";
, and I have the error below. I found AsyncComputed is a class. It is not a decorator any more? In #25 it was a decorator. I could not find a document to know how to use vue-async-computed in TypeScript. So, could you tell me how to use vue-async-computed in TypeScript?

I could use 3.8.1 in my project: https://github.com/nwtgck/piping-ui-web/pull/131/files.


(added)
Is there any plan to support a decorator for TypeScript? If not, could you export interface IAsyncComputedValue<T>? It will help me to create a decorator without duplicate type-definitions.

from vue-async-computed.

foxbenjaminfox avatar foxbenjaminfox commented on August 30, 2024

I'm glad that v3.8.1 now works for you. I could definitely export the IAsyncComputedValue interface if you want to use it to write a decorator, but I'll actually do you one better: if you'd like to open a PR with your decorator, I'd be happy to merge it. That way everyone else can also benefit from the decorator as well.

All in all, I'm happy to take contributions to this or indeed to any part of vue-async-computed, but it is rather unlikely that I'll end up adding anything typescript-related myself.

from vue-async-computed.

nwtgck avatar nwtgck commented on August 30, 2024

@foxbenjaminfox Thanks! I made #88.

from vue-async-computed.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.