DEV Community

Cover image for The Real Problem With vibe-Coding or Why Faster is slower?
Rákóczi Piroska
Rákóczi Piroska

Posted on

The Real Problem With vibe-Coding or Why Faster is slower?

If you expect security and efficiency with an AI coder like Replit, you need to follow strict workflow rules. I'll just briefly talk about them. This way of working doesn't take away from the experience that Replit can provide, that you can code quickly something that your intern can code slowly, but if you also write prompts to prevent and/or fix Replit's errors - well, that makes the faster one slower. Why?

You will need at least 6 prompts

These prompts are the followings. These were useful in a certain case. Making them useful you should apply to your project.

A security guard prompt
“Help me implement [TASK] in Python, following strict security rules:

  • Use only well-known, actively maintained libraries.
  • Avoid newly published or obscure packages.
  • Pin all dependency versions explicitly (package==x.y.z).
  • Never include API keys or secrets in code. Use environment variables.
  • Before finalizing, simulate a pip-audit and flag known vulnerabilities.
  • Validate all user inputs against injection or malicious data.”

A transparency prompt
"Modify popup.css [your request]. Strict condition: List each file you plan to modify before you start coding! If you need to touch popup.js or manifest.json in addition to CSS, explain exactly why. Do not make 'silent' changes to files that you did not mention in your answer!"

A diff summary prompt
"I see that the content of the popup.js file has also changed, even though it was only the CSS. Generate me a complete list of all the files you modified in the last round! Write a sentence next to each file explaining exactly what you changed and why. In the future, start all your answers with a 'Change Log' like this before you update any code!"

A lockdown prompt
"We are currently working exclusively with the popup.css file. I am disabling access to edit the popup.js and manifest.json files for this round. If my request cannot be fulfilled without modifying the JS, then do not write code, but report the technical obstacle! Work only in the file I have designated and do not perform background work on other modules!"

A structural inspector prompt
"My goal is to update the look of the Chrome extension in popup.css. Don't generate new HTML elements from Javascript, and don't change event listeners. If you feel like you need to change popup.js for a design element, stop and ask me before you rewrite anything! Just work with the existing CSS selectors for now."

A code quality enforcement prompt
"Act like a Senior Full-stack Developer. Take a critical look at the current state of [filename]. It seems like we've produced 'spaghetti code' while fixing the bug. Please don't just fix the bug, but refactor the code: make it modular, clean, and follow [language/framework, e.g. React] best practices. Pay special attention to type safety and error handling to avoid similar regression bugs."

How could this be made faster?

At first it will be even slower, because you will have to save all the prompts you have written. It would be best if you had a Chrome extension that would save the prompts with a single click after you type them. The extension would organize the prompts into an FAQ-like system. Then you would just have to access the Chrome extension, find the prompt and CTR C, CRT V. Are you interested in such an extension? Write it in the comments, please.

Top comments (0)