Skip to content
CLI that help you to improve the SEO and UX of your websites.
Python HTML
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github
.idea
cushead.egg-info
dist
docs
src
testing
.coverage
.coveragerc
.editorconfig
.gitignore
.restyled.yaml
.travis.yml
LICENSE.md
MANIFEST.in
README.md
TODO
__init__.py
codecov.yml
cushead.py
dev-requirements.txt
pyproject.toml
requirements.txt
setup.cfg
setup.py

README.md

Build Status Codacy Badge codecov PyPI version

cushead logo

CUSHEAD

Improve the SEO and the UX of your website.

Python Versions: >=3.6, <4.0

Package Version: *

Status: Development

Description

Generates a basic structure of the files of a static website, with a main focus on SEO and UX.

View example

Usage

-default --images

cushead.py -default custom_settings.json --images

Generate a default config file with images includes

custom_settings.json

Can edit all of this settings.

{
  "comment":  {
      "About":            "Config file used by python CUSHEAD",
      "Format":           "JSON",
      "Git":              "https://github.com/lucasvazq/cushead",
      "Documentation":    "https://github.com/lucasvazq/cushead/blob/master/README.md"
  },
  "required": {
      "static_url":       "/static/"
  },
  "recommended": {
      "favicon_ico":      "./favicon_ico_16px.ico",
      "favicon_png":      "./favicon_png_1600px.png",
      "favicon_svg":      "./favicon_svg_scalable.svg",
      "preview_png":      "./preview_png_500px.png"
  },
  "default": {
      "general": {
          "content-type":     "text/html; charset=utf-8",
          "X-UA-Compatible":  "ie=edge",
          "viewport":         "width=device-width, initial-scale=1",
          "language":         "en",
          "territory":        "US",
          "clean_url":        "microsoft.com",
          "protocol":         "https://",
          "robots":           "index, follow"
      },
      "basic": {
          "title":            "Microsoft",
          "description":      "Technology Solutions",
          "subject":          "Home Page",
          "keywords":         "Microsoft, Windows",
          "background_color": "#FFFFFF",
          "author":           "Lucas Vazquez"
      },
      "social_media": {
          "facebook_app_id":  "123456",
          "twitter_user_@":   "@Microsoft",
          "twitter_user_id":  "123456"
      }
  },
  "progressive_web_apps": {
      "dir":              "ltr",
      "start_url":        "/",
      "orientation":      "landscape",
      "scope":            "/",
      "display":          "browser",
      "platform":        "web",
      "applications":     [
          {
              "platform":     "play",
              "url":          "https://play.google.com/store/apps/details?id=com.example.app",
              "id":           "com.example.app"
          },
          {
              "platform":     "itunes",
              "url":          "https://itunes.apple.com/app/example-app/id123456"
          }
      ]
  }
}
Images
  favicon_ico_16px.ico
  favicon_png_1600px.png
  favicon_svg_scalable.svg
  preview_png_500px.png

-config

cushead.py -config custom_settings.json

Run the script with the custom config generated with -default --images. This will generate the website structure

List output

*/: the folder where is the settings json file.

*STATIC/: The statics files folder. It depends on the 'static_url' key in the settings file.

*IMAGES/: A tons of images files in png format, and one in svg.

*/
├─ custom_settings.json
└── /output
    ├── index.html
    ├── favicon.ico
    ├── robots.txt
    ├── sitemap.xml
    └── *STATIC/
        ├── manifest.json
        ├── browserconfig.xml
        └── *IMAGES/

Testing

Files

manifest.json

robots.txt

sitemap.xml

Headers

Favicons

Meta-tags

Facebook Debugger

Twitter Card validator

Considerations

Here is a list of concepts that comprise good practices to improve SEO and UX:

  1. Structured data: RDFa, JSON-D, Microdata, GoodRelations, vCard, hCard
  2. rel profile attribute for referring to author or website owner
  3. ARIA Labels (with role attribute)
  4. title attribute to links
  5. Maskable icons
  6. Accelerated Mobiles Pages
  7. Progressive Web Apps
  8. Screenshots in manifest for PWA
  9. Add PWA to App stores (like the Play Store of Google)
  10. Javascript and css minified and purged with short variables names
  11. Responsive Design
  12. Mobile call and Whatsapp sms for mobiles websites
  13. Google my Business integration
  14. gzip and bzip2 compression
  15. Server Side Rendering
  16. Client Side routing
  17. HTTP caching in Client Side
  18. Content Delivery Network
  19. Make svg files scalable
  20. Short and SEO related filenames
  21. svg files must be scalables
  22. Think when to use svg instead of img
  23. Minimize icon fonts
  24. Minify all files (html, css, js, json, xml, images)
  25. Purge javascript and css.
  26. Obfuscate, if can, css class names and js variablenames
  27. Benefit from html5 (<br> better than <br />)
  28. colorblind thinking (keep in mind the color of menus, lines, borders, shadows, and text when are designing website)

License

cushead © 2019 Lucas Vazquez. Released under the MIT License.

You can’t perform that action at this time.