Skip to content

Format python react code .Rules

Roman Myko edited this page Nov 4, 2024 · 1 revision

Format python code

python -m black . --exclude migrations

Rules .To the Import sequence React modules in code

  • Libraries (for example, React, Redux, React Router, and other npm libraries).
  • empty row
  • Components (start with more global components if any, then import internal components).
  • empty row
  • Custom hooks (if used).
  • empty row
  • Other resources (such as images or other specific imports).
  • empty row
  • CSS modules or styles (to ensure styles are applied before components that use them).
  • empty row
  • empty row
import { useState, useEffect } from 'react';

import axios from 'axios';