Drop in a screenshot and convert it to clean code (HTML/Tailwind/React/Vue)
Python
Merge branch 'main' into pr/7
Abi Raja87bbe4987af5
diff --cc README.mdindex 1365a69f,a8f7ec08..eb9725bc--- a/README.md+++ b/README.md@@@ -8,8 -10,10 +10,9 @@@ See [Examples](#examples) section belo## Updates-* Nov 16 - Added a setting to disable DALL-E image generation if you don't need that-* Nov 16 - View code directly within the app-* Nov 15 - 🔥 You can now instruct the AI to update the code as you wish. Useful if the AI messed up some styles or missed a section.-++- Nov 16 - Added a setting to disable DALL-E image generation if you don't need that+- Nov 16 - View code directly within the app+- Nov 15 - 🔥 You can now instruct the AI to update the code as you wish. Useful if the AI messed up some styles or missed a section.## Getting Started@@@ -37,26 -41,25 +40,38 @@@ Open http://localhost:5173 to use the aIf you prefer to run the backend on a different port, update VITE_WS_BACKEND_URL in `frontend/.env.local`+## Docker++If you have Docker installed on your system, you can get started quickly with:++```bash+echo "OPENAI_API_KEY=sk-your-key" > .env+docker-compose up -d --build+```++Application will be up and running at http://localhost:5173++Note that you can't develop the application with this setup as the file changes won't trigger a rebuild.+- ## Feedback+ ## FAQs- If you have feature requests, bug reports or other feedback, open an issue or ping me on [Twitter](https://twitter.com/_abi_).-* **I'm running into an error when setting up the backend. How can I fix it?** [Try this](https://github.com/abi/screenshot-to-code/issues/3#issuecomment-1814777959). If that still doesn't work, open an issue.-* **How do I get an OpenAI API key that has the GPT4 Vision model available?** Create an OpenAI account. And then, you need to buy at least $1 worth of credit on the [Billing dashboard](https://platform.openai.com/account/billing/overview).-* **How can I provide feedback?** For feedback, feature requests and bug reports, open an issue or ping me on [Twitter](https://twitter.com/_abi_).++- **I'm running into an error when setting up the backend. How can I fix it?** [Try this](https://github.com/abi/screenshot-to-code/issues/3#issuecomment-1814777959). If that still doesn't work, open an issue.++- **How do I get an OpenAI API key that has the GPT4 Vision model available?** Create an OpenAI account. And then, you need to buy at least $1 worth of credit on the [Billing dashboard](https://platform.openai.com/account/billing/overview).++- **How can I provide feedback?** For feedback, feature requests and bug reports, open an issue or ping me on [Twitter](https://twitter.com/_abi_).## Examples- Hacker News but it gets the colors wrong at first so we nudge it+ **NYTimes**+-| Original | Replica |-|----------|---------|++| Original | Replica |++| -------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------- |+ |  |  |++ **Instagram page (with not Taylor Swift pics)**++ https://github.com/abi/screenshot-to-code/assets/23818/503eb86a-356e-4dfc-926a-dabdb1ac7ba1++ **Hacker News** but it gets the colors wrong at first so we nudge ithttps://github.com/abi/screenshot-to-code/assets/23818/3fec0f77-44e8-4fb3-a769-ac7410315e5ddiff --cc frontend/src/generateCode.tsindex 77edf07c,c3e92187..3b0f3d6f--- a/frontend/src/generateCode.ts+++ b/frontend/src/generateCode.ts@@@ -1,9 -1,9 +1,9 @@@import toast from "react-hot-toast";const WS_BACKEND_URL =- import.meta.env.VITE_WS_BACKEND_URL || "ws://127.0.0.1:7000";+ import.meta.env.VITE_WS_BACKEND_URL || "ws://127.0.0.1:7001";const ERROR_MESSAGE =- "Error generating code. Check the Developer Console for details. Feel free to open a Github ticket";+ "Error generating code. Check the Developer Console for details. Feel free to open a Github issue";export interface CodeGenerationParams {generationType: "create" | "update";