Type '{ |cssProperties|}' is not assignable to type 'Properties' in React

https://stackoverflow.com/questions/69195076/type-cssproperties-is-not-assignable-to-type-propertiesstring-number

It's a little mismatch in typing of TypeScript. You would need to add CSSProperties interface for the style object.

import { CSSProperties } from "react";

const linkStyle: CSSProperties = {
  color: "#8954A8",
  fontWeight: "bold",
  fontSize: 16,
  verticalAlign: "5%" 

};

 

Không có nhận xét nào:

Is it okay to use both fetchpriority="high" and loading="eager" in img tag?

 https://stackoverflow.com/questions/77744344/is-it-okay-to-use-both-fetchpriority-high-and-loading-eager-in-img-tag Yes Fetchpriority and l...