Skip to content
| Marketplace
Sign in
Visual Studio Code>Snippets>react sinppetsNew to Visual Studio Code? Get it now.
react sinppets

react sinppets

ganesh bharti

|
908 installs
| (1) | Free
A collection of different react sinppets:
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

react-code-snippets README

A snippet library which includes simple daily use snippets

Languages supported

  1. Javascript(js)

  2. Typescript(ts)

  3. Javascriptreact(jsx)

  4. Typescriptreact(tsx)

All Commands - 7

  1. cl - Console Log
  2. cls - Console Log String
  3. clc - Console Section
  4. fc - functional Component
  5. us - functional Component with useState
  6. fcp - Arrow functional Component with Props
  7. race - React functional Component Export

Snippets

cl - Console Log

console.log();

cls - Console Log String

console.log("");

clc - Console Log sections

console.log();
console.count();
console.table();
console.error();
console.info();

race - React Arrow functional Component Export

import React from "react";

const FileName = () => {
  return <></>;
};
export default FileName;

fc - functional Component

const componentname = () => {
  return <></>;
};

us - functional Component with useState

const componentname = () => {
  const [use, setUse] = useState(0);
  return <></>;
};

fcp - functional Component with Props

const ComponentName = ({ props }) => {
  return <></>;
};

Contributing

The repo

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft