postcss-markdown icon indicating copy to clipboard operation
postcss-markdown copied to clipboard

upgrade remark to v11 to fix declaration error

Open Chersquwn opened this issue 6 years ago • 8 comments

Because of @types/vfile and @types/vfile-message deprecate, the old version of remark depends on @types/vfile-message will report an error, when using ts.

ERROR in [at-loader] ./node_modules/@types/vfile/index.d.ts:11:31 
    TS7016: Could not find a declaration file for module 'vfile-message'.

Chersquwn avatar Nov 14 '19 02:11 Chersquwn

@Chersquwn this is a duplicate of #31

XhmikosR avatar Nov 30 '19 14:11 XhmikosR

Possible temporary fix for Yarn users is to define resolutions in package.json:

{
  "resolutions": {
    "remark": "11.0.2"
  }
}

pmeller avatar Jan 15 '20 11:01 pmeller

Could you provide a new release with the updated remark dependency? Thank you!

de-dan avatar Jan 27 '20 16:01 de-dan

@gucong3000 Please publish the new version. postcss-markdown is currently the point of failure for a lot typescript builds.

HHogg avatar Feb 18 '20 23:02 HHogg

I added the following workaround to my custom-types.d.ts (project root file):

declare module 'vfile-message' {
  export type VFileMessage = any;
}

bobaaaaa avatar Feb 19 '20 07:02 bobaaaaa

Sadly, we don't have a new release. 😞

As a fix to vfile-message error, in my case, I just added "moduleResolution": "node" to tsconfig.json.

rafaelfbs avatar Mar 19 '20 02:03 rafaelfbs

As a fix to vfile-message error, in my case, I just added "moduleResolution": "node" to tsconfig.json.

@rafaelfbs new to typescript here, care to share example of what you added? we already have in tsconfig "moduleResolution": "node",

craigbeck avatar Apr 10 '20 23:04 craigbeck

any chance we'll get this fixed? it's almost been a year

NullVoxPopuli avatar Sep 21 '20 21:09 NullVoxPopuli