Giter Club home page Giter Club logo

Comments (6)

sodatea avatar sodatea commented on May 18, 2024

Please provide an actually runnable reproduction. I can't see the error from the provided link.

from core.

hona-app avatar hona-app commented on May 18, 2024

Please provide an actually runnable reproduction. I can't see the error from the provided link.

This problem must import any third Package which contains interface declaration, thus I can't supply a runable demo. Please Copy code to local to reproduction this.

from core.

edison1105 avatar edison1105 commented on May 18, 2024

https://vuejs.org/api/sfc-script-setup.html#type-only-props-emit-declarations

The latest version of Vue supports referencing imported and a limited set of complex types in the type parameter position. However, because the type to runtime conversion is still AST-based, some complex types that require actual type analysis, e.g. conditional types, are not supported. You can use conditional types for the type of a single prop, but not the entire props object.

from core.

hona-app avatar hona-app commented on May 18, 2024

In my project, I have many sub components(50+) which have the same props option, so I wan't to reuse entire props object, so I can reduce 98% coding of props object declaration, It's really useful in dynamic imported components seceneries.
SO: Will vue support this secenary, and when? Looking forward to it.

from core.

edison1105 avatar edison1105 commented on May 18, 2024

try https://github.com/so1ve/vue.ts/tree/main/packages/complex-types

from core.

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.