htmx

command module
v0.0.0-...-b5534ad Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 18, 2024 License: MIT Imports: 3 Imported by: 0

README

Starting your project

❗️ 下面是开发必须的工具和库,你可以在这里找到它们的文档和更多信息:

要开始您的项目,在终端中运行 Gowebly CLI命令:

gowebly run

或者:

air

Project overview

Backend:

  • Module name in the go.mod file: github.com/yumenaka/comigo/htmx
  • Go web framework/router: Gin
  • Server port: 1234

Frontend:

  • Package name in the package.json file: comigo
  • Reactivity library: htmx with Alpine.js
  • CSS framework: Tailwind CSS with daisyUI components

Tools:

  • Air tool to live-reloading: ✓
  • Bun as a frontend runtime: ✓
  • Templ to generate HTML: ✓
  • Config for golangci-lint: ✓

Folders structure

.
├── assets
│   ├── scripts.js
│   └── styles.scss
├── static
│   ├── images
│   │   └── gowebly.svg
│   ├── apple-touch-icon.png
│   ├── favicon.ico
│   ├── favicon.png
│   ├── favicon.svg
│   ├── manifest-desktop-screenshot.jpeg
│   ├── manifest-mobile-screenshot.jpeg
│   ├── manifest-touch-icon.svg
│   └── manifest.webmanifest
├── templates
│   ├── pages
│   │   └── index.templ
│   └── main.templ
├── .gitignore
├── .dockerignore
├── .prettierignore
├── .air.toml
├── golangci.yml
├── Dockerfile
├── docker-compose.yml
├── prettier.config.js
├── package.json
├── go.mod
├── go.sum
├── handlers.go
├── server.go
├── main.go
└── README.md

Developing your project

The backend part is located in the *.go files in your project folder.

The ./templates folder contains Templ templates that you can use in your frontend part. Also, the ./assets folder contains the styles.scss (main styles) and scripts.js (main scripts) files.

The ./static folder contains all the static files: icons, images, PWA (Progressive Web App) manifest and other builded/minified assets.

Deploying your project

All deploy settings are located in the Dockerfile and docker-compose.yml files in your project folder.

To deploy your project to a remote server, follow these steps:

  1. Go to your hosting/cloud provider and create a new VDS/VPS.
  2. Update all OS packages on the server and install Docker, Docker Compose and Git packages.
  3. Use git clone command to clone the repository with your project to the server and navigate to its folder.
  4. Run the docker-compose up command to start your project on your server.

❗️ Don't forget to generate Go files from *.templ templates before run the docker-compose up command.

About the Gowebly CLI

The Gowebly CLI is a next-generation CLI tool that makes it easy to create amazing web applications with Go on the backend, using htmx, hyperscript or Alpine.js, and the most popular CSS frameworks on the frontend.

It's highly recommended to start exploring the Gowebly CLI with short articles "What is Gowebly CLI?" and "How does it work?" to understand the basic principle and the main components built into the Gowebly CLI.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
templates
components
templ: version: v0.2.771
templ: version: v0.2.771
pages
templ: version: v0.2.771
templ: version: v0.2.771

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL