vscode-react-javascript-snippets icon indicating copy to clipboard operation
vscode-react-javascript-snippets copied to clipboard

Snippets `rmc` and `rmcp` missing component name。

Open ganyanchuan1989 opened this issue 1 year ago • 2 comments

version: v4.4.3 hot key: rmc output:

import React, { memo } from 'react'

const Comp = memo(() => {
  return (
    <div>Comp</div>
  )
})

export default Comp

This way of declaring loses the name of the component in React Developer Tools。I wish as follows:

import React, { memo } from 'react'

const Comp = () => {
  return (
    <div>Comp</div>
  )
}

export default memo(Comp)

or

import React  from 'react'

const Comp = () => {
  return (
    <div>Comp</div>
  )
}

export default React.memo(Comp)

ganyanchuan1989 avatar Feb 27 '23 01:02 ganyanchuan1989

Hi, I want to work on this. Please assign me.

theavitw avatar Mar 03 '23 05:03 theavitw

Hi, I want to work on this. Please assign me.

What if he doesn't assign it to you and you submit mr yourself?

LukerSpringtree avatar Mar 09 '23 03:03 LukerSpringtree