frontlessdev / frontless-js

Frontless is a backend web framework that create Web and native Flutter UI.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Frontless-js

Installation

Install Bun if not installed.

curl -fsSL https://bun.sh/install | bash

Create a directory, and initialize your project.

mkdir myserver
cd myserver
bun init

Install frontlessjs.

bun add frontlessjs

Hello World

Create a index.ts in your project

// index.ts
import frontless, { type Widget } from "frontlessjs"
import { text } from "frontlessjs/material"
const app = frontless()
app.page("/", async (): Promise<Widget> => {
      return text("Hello World!")
})
app.listen(3000)

Run your app.

bun index.ts

Then visit localhost:3000 in your browser to see the page!

Learn More

Doc&Examples: https://www.frontless.dev/

About

Frontless is a backend web framework that create Web and native Flutter UI.

License:MIT License


Languages

Language:TypeScript 96.0%Language:JavaScript 2.8%Language:CSS 1.2%