Giter Site home page Giter Site logo

woodvip / hexo-theme-jsimple Goto Github PK

View Code? Open in Web Editor NEW

This project forked from tangkunyin/hexo-theme-jsimple

0.0 0.0 0.0 23.04 MB

Simple three columns theme for Hexo.Inspired by JianShu.com

Home Page: https://shuoit.net

License: MIT License

HTML 2.19% CSS 44.96% JavaScript 33.31% Shell 0.16% EJS 19.38%

hexo-theme-jsimple's Introduction

JSimple

Build Status

JSimple is a responsive blog theme for Hexo which include day-night mode, local search, article view count etc. Inspired by JianShu that in the earliest.

JSimple-Snapshot-Macbook Pro15

Installation

  1. Get it from GitHub
$ git clone https://github.com/tangkunyin/hexo-theme-jsimple themes/jsimple
  1. Enable

Modify theme setting in _config.yml to jsimple.

To use of the local search, please add hexo-generator-search

  1. Update
$ cd themes/jsimple
$ git pull

Configurations

For a quick start, see my Site backup may be more convenient.

site _config.yml

# choose your language. default Chinese
language:
    - en
    - zh-cn

# URL (Notice the permalink. Variable timestamp in post.md was added from hexo lib source)
##  Please see the scripts in patch dir for more details
url: https://shuoit.net
root: /
permalink: :category/:entitle-:timestamp.html
permalink_defaults:
  lang: en

# Local search
search:
  path: search.json
  field: all
  content: true
  
# Category alias
default_category: Tech
category_map:
   Tech: tech-notes
tag_map:
  hexo: hexo

theme _config.yml

# Master information. At the other hand, the fields int post.md(author|avatar|authorLink|authorAbout|authorDesc)also have the same effects
## The priority in article config is higher than theme when you configuring at the same time. This used for multiplayer creation 
webmaster:
  name: Thomas Tang
  avatar: /images/favicon.png
  home: https://shuoit.net
  desc: Senior Chinglish writer and coder😁️️

# Decide whether the 'Content-Security-Policy = upgrade-insecure-requests' will be add in head tag.
csp_enable: false

# Article sort mode: -1(newer first),1(older first). home_article_shown means paging count
home_page_sort: -1
home_article_shown: 10

# Article category navigation 
menu:
  Tech: tech-notes
  Life: humanities

# Left navigation link. The faName is in FontAwesome styles.
left_nav_menus:
- uri: help
  title: Help
  faName: fa-question-circle
  
  
# Google AdSense. Support auto-ads and manual-unit
adsense:
  enable: false// manual-unit-ads
  auto: false// auto-ads
  client_id:
  archive_id:
  tags_id:    
  post_left_id:
  post_right_id:
  post_bottom_id:


# Only support Disqus and Gitment so far.
comments:
  enable: false
  disqus_shortname:
  gitment:
    repo:
    githubID:
    ClientID:
    ClientSecret:
    lazy: true

Other config

Search Module

Because of the search in previous version didn't work well. Such as highlight content, responsive problem in small screen.

So I replace it with hexo-generator-search. Thanks for Next theme.

There are two Chinese articles that told how to create local-search in hexo.

How sticky top and timestamp works

I have made some changes in hexo lib source code so that timestamp and sticky datasource could get when hexo-cli generating articles.

From version 0.0.7, JSimple have been adding patch scripts. You need to excute patch/run.sh when node_modules was deleted.

You have to copy the patch dir into your site dir, otherwise sticky top and timestamp in permalink will not work.

AdSence

From version 0.0.7. Google AdSense have been added. If you don't need this, just close it.

The other things about JSimple

If you don't understand Chinese. You can translate online by Google Translate 🤣🤣🤣

Browser support

Contributing

All kinds of contributions (enhancements, new features, documentation & code improvements, issues & bugs reporting) are welcome.

Looking forward to your pull request.

Special thanks to iTimeTraveler and jiangmuzi, who designed the theme Hipaper and JianShu.

License

JSimple is under the MIT license. See the LICENSE file for details.

Thanks

Hexo Font Awesome

hexo-theme-jsimple's People

Contributors

linsanzhu avatar dependabot[bot] avatar longqzh avatar stonecypher avatar liaobinbin avatar tangkunyin avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.