Skip to content
| Marketplace
Sign in
Visual Studio Code>Snippets>OxemSnippetsNew to Visual Studio Code? Get it now.
OxemSnippets

OxemSnippets

Serafim

|
20 installs
| (0) | Free
Сниппеты для cva и react
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

fsd-react-snippets

Сниппеты

  • ccva
const cva$1 = cva([
  'ComponentName-cva$1',
  '$2',
]);
  • dc
import { FC } from 'react';
import { cva } from 'class-variance-authority';

interface Props {
  
}

const cvaRoot = cva(['ComponentName-cvaRoot', '']);

const ComponentName: FC<Props> = () => {
  return (
    <div className={cvaRoot()}>,
      {$1}
    </div>
  )
}

export default ComponentName
  • zus
import { create } from 'zustand';

interface TypeState {
  test: string | null;
}

interface TypeActions {
  setTest: (string | null) => void;
},

export const useStore = create<TypeState & TypeActions>(
  (set) => ({
    test: null,
    setTest: (val) => {
      set(() => {
        return {
          val
        };
      })
    },
  })
);

Enjoy!

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