title | description | tags | ||||
---|---|---|---|---|---|---|
Angular + Ionic + Caddy |
The default Ionic Angular starter, utilizing `Caddy` to serve the built single page app |
|
This project was originally generated with ionic start
- Ionic + Angular + Caddy
- Caddy v2
- Install required dependencies with
npm install
- Run
npm start
for a development server - Navigate to
http://127.0.0.1:4200/
. The application will automatically reload if you change any of the source files.
To get more help on the Ionic CLI use ionic help
or go check out the Introduction to Ionic page.
Caddy is a powerful, enterprise-ready, open source web server, and therefore Caddy is far better suited to serve websites than ng serve
is, using Caddy will result in much less memory and cpu usage compared to serving with ng serve
(much lower running costs too)
To see how this is achieved with nixpacks, check out the fully documented nixpacks.toml file in this repository
The configuration for Caddy is called a Caddyfile, and you can edit that file to further suite your needs, by default it comes configured to serve a single page app for Angular, and to also gzip the responses
Relevant Caddy documentation: