Skip to content

1998code/Swift2HTML

Repository files navigation

Swift2HTML - Convert Swift code to HTML

Powered by OpenAI GPT Codex

Xnapper-2022-12-17-18 38 56

Supported Frameworks

image

Features

  • Swift Input
  • HTML Output
  • HTML Preview
  • Light / Dark Mode
  • AutoPilot (Refresh per input) / Manual Update (Default)
  • FontAwesome Icon Replacement
  • OpenAI GPT Codex Integration
  • Select CSS Framework (Reserved)

Getting Started

First, run the development server:

npm run dev
# or
yarn dev

Open http://localhost:3000 with your browser to see the result.

You can start editing the page by modifying pages/index.tsx. The page auto-updates as you edit the file.

API routes can be accessed on http://localhost:3000/api/openai. This endpoint can be edited in pages/api/openai.ts.

The pages/api directory is mapped to /api/*. Files in this directory are treated as API routes instead of React pages.

Dark Mode

CleanShot 2022-12-17 at 21 26 41@2x

Comment Available

CleanShot 2022-12-17 at 21 27 40@2x

Limitation

  • Accuracy and generation may be various in every trial.
  • Incorrect conversion to Pixel, e.g., width: 300 => w-300, where suppose only w-[300px] can work fine. Of course, the scaling is incorrect too.
  • Limited tokens.

License

MIT