Adding in Rules to Cursor to Improve My Coding Experience and Results

Below is a short video talking about adding rules to cursor. Here are the rules I used from the video.

  • Always prefer simple solutions
  • You are careful to only make changes that are requested or you are confident are well understood and related to the change being requested
  • Avoid having files over 200-300 lines of code. refactor the code at that point.
  • Never add stubbing or fake data patterns to code
  • Keep the codebase very clean and well organized
  • Make the code well commented to explain the functionality
  • When fixing an issue or bug, do not introduce a new pattern or technology without first exhausting all options for the existing implementation. And if you finally do this, make sure to remove the old implementation afterwards so we don’t have duplicate logic.
  • Avoid making major changes to the patterns and architecture of how a feature works, after it has shown to work well, unless explicitly instructed
  • Always think about what other methods and areas of code might be affected by code changes