Socket
Book a DemoInstallSign in
Socket

create-honc-app

Package Overview
Dependencies
Maintainers
2
Versions
45
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

create-honc-app

An interactive CLI to create modular typesafe data APIs using TypeScript

1.6.1
latest
Source
npmnpm
Version published
Weekly downloads
3
-66.67%
Maintainers
2
Weekly downloads
 
Created
Source

Honc Honc!

Scaffolding CLI for creating modular data APIs using TypeScript

npm create honc-app@latest

HONC is a modular collection of choice technologies for building lightweight, type-safe, edge-enabled data apis that scale seamlessly to their demand.

🪿 Hono as an api framework
🪿 Neon for a relational Postgres database
🪿 Drizzle as the ORM and migrations manager
🪿 Cloudflare Workers for deployment hosting

📚 For more examples and templates, check out the Awesome Honc repository.

Quickstart

To get started run the following command:

npm create honc-app@latest

You'll be prompted a few simple questions, and then a fresh HONC project will arrive in a new directory on your machine.

Commands

Run the development server:

npm run dev

Once you've set up a Neon database (see below) and added the connection string to a DATABASE_URL=.. in dev.vars, you can generate some migrations, apply them, and seed the database:

npm run db:generate
npm run db:migrate
npm run db:seed

If you're inclined to deploy the app to the wild wild internet, you can do so as follows (requires a Cloudflare account):

npm run deploy

Setting up a Neon database

Create a Neon account and project, retrieve the connection key from the dashboard, and add it to your dev.vars file.

Alternatively, you can use the Neon CLI to create a project and set the context:

# Authenticate with neon cli
neonctl auth

# Create project if you haven't already
#
# > *skip this* if you already created a project,
# > and grab the DATABASE_URL from your dashboard
PROJECT_NAME=my-project
neonctl projects create --name $PROJECT_NAME --set-context

# Set project id because the call to `set-context` below needs it
PROJECT_ID=$(neonctl projects list --output=json | jq --arg name "$PROJECT_NAME" '.projects[] | select(.name == $name) | .id')

# Create a `dev` db branch then set context
BRANCH_NAME=dev
neonctl branches create --name=$BRANCH_NAME
neonctl set-context --project-id=$PROJECT_ID --branch=$BRANCH_NAME

# Finally, add connection string to .dev.vars
DATABASE_URL=$(neonctl connection-string)
echo -e '\nDATABASE_URL='$DATABASE_URL'\n' >> .dev.vars

This will create a .neon file, which is used by the neonctl command to know the proper context for running commands.

This file can be kept in version control. From the Neon docs:

Neon does not save any confidential information to the context file (for example, auth tokens). You can safely commit this file to your repository or share with others.

More resources

See the examples folder for some sample APIs.

We have an Awesome HONC repository with further guides, use cases and examples.

FAQs

Package last updated on 09 Jul 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.