- Notifications
You must be signed in to change notification settings - Fork9
Your landing page and leads manager out-of-the-box with Node.js+Express
License
pasalino/TinyLanding
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Your multi landing page and leads managerout-of-the-box with Node.js+Express.
Create your landing page system infrastructure in30 seconds. TinyLanding is the easy out-of-the-box system for storingyour leads in a sqlite database and manage it. Use only HTML to create your landing page and don't worry about anything else. TinyLanding is written in Node.js + Express and is ready to use for all JavaScript developers.
- Easily create a landing page using HTML and CSS
- Create multi landing pages in one system
- Out-of-the-box leads system
- Export leads in CSV
- Admin receives an email for each lead form submitted
- Use CsrfToken for security
- Compress the output in minified mode
- Use sqlite
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.
Clone this repository to your destination and edit.
git clone git@github.com:pasalino/TinyLanding.git
Usenpm
oryarn
to install. Go to project folder and use the install command. Post-install scripts will run after all dependencies are installed.
npm install
The post-install scriptW create and execute all migrations on your Sqlite database.
The db file is placed in theapp/data
folder. You can change all db connection properties in the config file atapp/config/database.json
. Use thedevelopment key in your development environment and theproduction key when you are ready to switch TinyLanding to production mode.
Copyapp/config/email_dist.json
and rename it toapp/config/email.json
. Edit the default configuration with your email details. Same as for the db config file, usedevelopment andproduction keys respectively in development and production mode.
In this version the email password setting isn't crypted. Remember to use an email other than yours or to hide this file from prying eyes.
TinyLanding is the best way for frontenders and webdesigners to quickly boot up a HTML landing page with a lead contact form.The system usemustache view engine system. You use your HTML, CSS and scripts directly in the mustache file.
Change fileapp/views/landing_anem/index.mustache
with your HTML to create your personal web page.
- (Under construction) Include template form.mustache in landing page
- (Under construction) Include JQuery and main.js scripts
- (Under construction) Include main.css
- (Under construction) Errorfile
All public assets are in theapp/public/landing_name
folder. This file is reached from the root url. Include all your CSS, scripts, images and other assets in this folder.
TinyLanding will send an email to the admin configured in email.json for each lead form submitted. You can personalize the email inapp/templates/lead.mustache
. This file uses the same view engine of HTML: mustaches.
Remember to use absolute URLs for images and embedded CSS stylesheets for this file.
Run the system using thenpm start
command.
TinyLanding uses an out-of-the-box system to store leads in your db. Sqlite is currently the only available db. You can use the script manager to read your leads.
Usebin/manage.js
to manage your landing page and your leads.
- (Under construction)
Usebin/manage.js --help
to show commands list
Use this command to use TinyLanding in production:
NODE_ENV=production PORT=80 npm start
In production, TinyLanding uses optimized settings:
- Compress with gzip and minify all responses
- Record error logs in
/app/data/log
- Use caching system
- Use standard 80 http port
If you want to listen to a different port use
PORT=[port_number]
as an argument when running the script.
Remember to use a process manager for production mode (e.g.PM2)
A process manager is a “container” for applications that facilitates deployment, provides high availability, and enables you to manage the application at runtime.
You can create a docker container:
Build
Run
You can use docker-compose to run TinyLanding in production
- Istructions for creating PM2 Services
- Provisioning on Heroku
- Documentation for editing the template
- Documentation for running in docker
- Create config system
- Add Test
- Add linter for JavaScript client-site
- Add linter for CSS
- Add linker for HTML
Pasqualino de Simone @pasalino
Please readCONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.
We useSemVer for versioning. For the versions available, see theTags.
This project is licensed under the MIT License - see theLICENSE.md file for details.
About
Your landing page and leads manager out-of-the-box with Node.js+Express