Code Monkey home page Code Monkey logo

Comments (2)

idux-bot avatar idux-bot commented on June 30, 2024

Translation of this issue:

usenotification uses an error []

REPRODUCTION LINK

STEPS To Reproduce

import {usenotification} from '@IDPONENTS/NOTIFICATION'
const notification = usenotification ()
Notification.error ({title: 'error', content: $ error code: $ {code}})

What is exfected?

What is actually happy?

TS grammar error
The parameters of the type "{title: string; content: string;}" cannot be assigned to the parameter of the type "Omit <ptificationOptions ," Type ">.
Type "{title: string; content: string;}" lacks the attribute "key", but the type "Omit <ptificationOptions ," Type ">" "Type".TS (2345)
Types.d.ts (69, 5): Here the "Key" was declared.

ENVIRONMENT Info

ANY Additional Comments? (Optional)

Among them, the key of notificationOptions is a must -value value, and the document does not explain what the key should fill in

from idux.

danranVm avatar danranVm commented on June 30, 2024

Key 就是组件的唯一标识,跟 v-for 中的 key 是一个作用。
不过这个地方应该不是必传的,是 ts 的类型声明写错了,下个版本修复。

from idux.

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.