Skip to content

Commit

Permalink
πŸ“– DOC: Improve documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
luangjokaj committed Dec 9, 2020
1 parent 3b99357 commit 31614ec
Show file tree
Hide file tree
Showing 8 changed files with 166 additions and 133 deletions.
14 changes: 14 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
root = true

[*]
quote_type = single
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
indent_style = tab
indent_size = 1

[*.yml]
indent_style = space
indent_size = 2
28 changes: 12 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
# [![FuzzyMail](https://github.com/luangjokaj/fuzzymail/raw/master/src/assets/img/logo.svg?sanitize=true)](https://www.fuzzymail.co/)
![Version](https://img.shields.io/github/package-json/v/luangjokaj/fuzzymail) [![Dependencies](https://david-dm.org/luangjokaj/fuzzymail/status.svg)](https://david-dm.org/luangjokaj/fuzzymail)

[![Version](https://img.shields.io/github/package-json/v/luangjokaj/fuzzymail)](https://www.fuzzymail.co/) [![Dependencies](https://img.shields.io/david/luangjokaj/fuzzymail)](https://www.fuzzymail.co/)

| Information | Discord | Donate |
|:------------|:---------|:-------|
| [FuzzyMail](https://www.fuzzymail.co/) is Email template generator. Making emails fun again ✌<br><br>**Problem:** Supporting old email clients it's a real pain. I wanted to create something that can be flexible in design and yet support legacy email clients like Outlook.<br><br>**Solution:** FuzzyMail - is a simple tool for generating email templates. Supporting old email clients while maintaining responsiveness. Fuzzymail is supported on over 60+ email clients.| [![Discord server](https://svgshare.com/i/Lqc.svg)](https://discord.gg/qE7e93) | [![BuyMeACoffee](https://www.buymeacoffee.com/assets/img/guidelines/logo-mark-1.svg)](https://www.buymeacoffee.com/luangjokaj) |
| [FuzzyMail](https://www.fuzzymail.co/) is Email template generator. Making emails fun again ✌<br><br>**Problem:** Supporting old email clients it's a real pain. I wanted to create something that can be flexible in design and yet support legacy email clients like Outlook.<br><br>**Solution:** FuzzyMail - is a simple tool for generating email templates. Supporting old email clients while maintaining responsiveness. Fuzzymail is supported on over 60+ email clients.| [![Discord server](https://svgshare.com/i/Lqc.svg)](https://discord.gg/uQFdMddMZw) | [![BuyMeACoffee](https://www.buymeacoffee.com/assets/img/guidelines/logo-mark-1.svg)](https://www.buymeacoffee.com/luangjokaj) |

[![Preview](https://i.imgur.com/VuKitHE.png)](https://www.fuzzymail.co/)
Demo Screenshots: [Modern Client](https://i.imgur.com/ETp8PaX.png) β€’ [Gmail](https://i.imgur.com/kSH90xr.png) β€’ [Outlook](https://i.imgur.com/Wi75S1q.png) β€’ [Mobile](https://i.imgur.com/YJgdCJg.png)
Expand All @@ -23,7 +24,7 @@ Demo Screenshots: [Modern Client](https://i.imgur.com/ETp8PaX.png) β€’ [Gmail](h

# Documentation
### Installation
FuzzyMail requires Node v7.5+. This is the only global dependency. You can download Node [**here**](https://nodejs.org/).
FuzzyMail requires **Node.js v12+**. This is the only global dependency. You can download Node.js [**here**](https://nodejs.org/).

## Setup project
### File Structure
Expand All @@ -37,32 +38,27 @@ FuzzyMail requires Node v7.5+. This is the only global dependency. You can downl
β”‚ β”œβ”€β”€ includes/ # HTML template partials
β”‚ β”œβ”€β”€ index.html # Index page
└── .gitignore # Git ignored files
└── .editorconfig # Editor code styles
└── gulpfile.js # Gulp configuration
└── LICENSE # License agreements
└── package.json # Node packages
└── package.json # Node.js packages
└── README.md # You are reading this
```

## Install FuzzyMail from NPM
To install FuzzyMail from NPM, run the command:
```
sudo npm i fuzzymail -g
```

**START FUZZYMAIL**

- Create a directory for the new email template and from there run FuzzyMail to generate the file structure:
```
fuzzymail
npx fuzzymail
```
That's it 🍾 easy as that. Now start the development workflow: [Start Workflow](#start-workflow)

## Install FuzzyMail from Repository
Clone repository:
```
git clone https://github.com/luangjokaj/fuzzymail
```

- This will clone the repository on your local machine. Navigate to the newly created folder.
- This will clone the repository on your local machine. Navigate to the newly created directory.

- Replace the file: `./package.json` with `./installer/package.json` and continue with the dependency installation.

Expand All @@ -72,12 +68,13 @@ git clone https://github.com/luangjokaj/fuzzymail
npm install
```

**START WORKFLOW**
## Start Workflow

- We are ready to start our development server with the command:
- To start the development server run the command:
```
npm run dev
```
- You are ready to go! Happy coding! πŸ€“

### Templating and HTML Partials
To avoid repetitive HTML code, FuzzyMail uses [gulp-file-include](https://github.com/haoxins/gulp-file-include). It has a simple templating synthax and allows to re-use chunks of code written in separate files. These partials are located in the directory:
Expand All @@ -87,7 +84,6 @@ src/includes/

For more information check out their documentation and examples: https://github.com/haoxins/gulp-file-include


### Production
To build the production templates:
```
Expand Down
23 changes: 15 additions & 8 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ function staticFilesDev() {
prefix: '@@',
basepath: '@file',
},
}),
})
)
.pipe(dest('./build'));
}
Expand Down Expand Up @@ -135,13 +135,13 @@ function staticFilesProd() {
prefix: '@@',
basepath: '@file',
},
}),
})
)
.pipe(
htmlmin({
collapseWhitespace: true,
ignoreCustomFragments: [/<%[\s\S]*?%>/, /<\?[=|php]?[\s\S]*?\?>/],
}),
})
)
.pipe(dest('./dist'));
}
Expand All @@ -153,7 +153,7 @@ function inlineStyles() {
applyStyleTags: true,
removeStyleTags: false,
removeLinkTags: false,
}),
})
)
.pipe(dest('./dist'));
}
Expand All @@ -164,7 +164,7 @@ function processImages() {
.pipe(
imagemin([imagemin.svgo({ plugins: [{ removeViewBox: true }] })], {
verbose: true,
}),
})
)
.pipe(dest('./dist/assets/img'))
.on('end', () => {
Expand All @@ -174,12 +174,18 @@ function processImages() {
});
}

exports.prod = series(cleanProd, stylesProd, staticFilesProd, processImages, inlineStyles);
exports.prod = series(
cleanProd,
stylesProd,
staticFilesProd,
processImages,
inlineStyles
);

/* -------------------------------------------------------------------------------------------------
Utility Tasks
-------------------------------------------------------------------------------------------------- */
const onError = err => {
const onError = (err) => {
gutil.beep();
gutil.log(fuzzyMail + ' - ' + errorMsg + ' ' + err.toString());
this.emit('end');
Expand All @@ -189,7 +195,8 @@ const onError = err => {
Messages
-------------------------------------------------------------------------------------------------- */
const errorMsg = '\x1b[41mError\x1b[0m';
const filesGenerated = 'Your production file are generated in: \x1b[1m' + __dirname + '/dist/ βœ…';
const filesGenerated =
'Your production file are generated in: \x1b[1m' + __dirname + '/dist/ βœ…';

const fuzzyMail = '\x1b[42m\x1b[1mπŸ“¨ FuzzyMail\x1b[0m';
const fuzzyMailUrl = '\x1b[2m - https://www.fuzzymail.co/\x1b[0m';
Expand Down
10 changes: 5 additions & 5 deletions installer/modules/printNextSteps.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,22 +29,22 @@ module.exports = () => {
console.log('\n✊ ', chalk.black.bgYellow(' Support FuzzyMail \n'));
console.log('Like FuzzyMail? Check out our other free and open source repositories: \n');
console.log(
` ${chalk.yellow('WordPressify β†’')} https://bit.ly/2KTqyQX`,
` ${chalk.yellow('WordPressify β†’ ')} https://bit.ly/2KTqyQX`,
'\n',
` ${chalk.gray('Development workflow for WordPress themes.')}`,
'\n',
` ${chalk.yellow('GoPablo β†’')} https://bit.ly/2Hgkfpy`,
` ${chalk.yellow('GoPablo β†’ ')} https://bit.ly/2Hgkfpy`,
'\n',
` ${chalk.gray('GoPablo is a static site generator.')}`,
'\n',
` ${chalk.yellow('ReactFondue β†’')} https://bit.ly/2OXgStR`,
` ${chalk.yellow('ReactFondue β†’ ')} https://bit.ly/2OXgStR`,
'\n',
` ${chalk.gray('SEO optimized React applications with SSR.')}`,
'\n',
` ${chalk.green('Powered by Riangle β†’')} https://bit.ly/2P5i26I`,
` ${chalk.green('Powered by Riangle β†’ ')} https://bit.ly/2P5i26I`,
'\n',
'\n',
` ${chalk.red('Thank you for using πŸ“¨ FuzzyMail β†’')} https://www.fuzzymail.co`,
` ${chalk.red('Thank you for using πŸ“¨ FuzzyMail β†’ ')} https://www.fuzzymail.co`,
);

// Get started.
Expand Down
Loading

0 comments on commit 31614ec

Please sign in to comment.