Skip to content

Latest commit

 

History

History
47 lines (29 loc) · 1.71 KB

README.md

File metadata and controls

47 lines (29 loc) · 1.71 KB

Modelina Website

This website is a Next + TypeScript website.

The website is being deployed to Netlify along side serverless functions.

How to run it

It uses the local version of Modelina, which means that before you run the website, make sure you build Modelina through npm run build:modelina.

Playground

Here is a quick overview of where some of the functions for rendering the playground work:

  • /src/helpers/GeneratorCode contains all the functions for creating the generator code, shown instead of the options.
  • /src/pages/api/functions contain all the individual generators that when the frontend calls the API /api/generate will perform the code generation with Modelina.
  • src/components/playground/PlaygroundOptions.tsx is the main component that renders the options based on which output is selected.
  • src/components/playground/options contain all the individual react components for showing the output options.
  • src/components/playground/Playground.tsx is the main playground component, and is the one rendered by the playground page.
  • src/components/playground/GeneratedModels.tsx is the playground component responsible for rendering the generated models.

Run Modelina Website locally

Checkout documentation that explains git-workflow used in our repositories.

  1. Navigate to the website directory.
    cd modelina-website
  1. Install all website dependencies.
    npm install
  1. Run the website locally.
    npm run dev
  1. Access the live development server at localhost:3000.

You'll be able to access the development server and you can contribute accordingly.