GithubHelp home page GithubHelp logo

middleman-webpack-boilerplate's Introduction

In Brief

This site is developed with Middleman, a static site generator, and therefore requires no relational database. Middleman (combined with Webpack) watches and compiles all files and assets. Use NPM (preferred) or Bower to manage vendor packages.

Features/Packages: BrowserSync, Webpack, Breakpoint-sass, and so much more!

Requirements: Ruby and Node/NPM (using rbenv and nodenv to manage is recommended)

Installation

first run bundle and then run yarn (or npm install) in terminal within the project's root directory

note: This project has only been tested with ruby v2.4.2 and node v8.9.4 / npm v6.9.4

Getting Started

Webpack is integrated into the middleman build workflow so only middleman commands should be used in the command line.

middleman serve will start the local dev environment and trigger webpack. Webpack will watch all assets then recompile and livereload the changes. Visit http://localhost:4567 to see the site in browser.

middleman build will compile the full static site into a /build/ directory (See additional caveats at bottom of this page)

##Project Files ASSETS: All SCSS and Javascript assets are located within their respective directorys within ./source/

HTML: All html files are located within the ./source/ directory within the root of the project. Since middleman is ruby, all html files must be appended with .erb and can run erb templating and digest any yaml front matter, or yaml/json within the ./data/ directory

  • Proxy Pages (aka Dynamic Pages): ./source/templates/page.html.erb is a template file that grabs subpage data within the "page" array in ./data/main.yml The configuration for this is within ./config.rb:
data.main.pages.each do |page|
    proxy "/#{page.slug}.html", "/templates/page.html", :locals => { :page => page }, :ignore => true
end

middleman-webpack-boilerplate's People

Contributors

wdeer avatar

Watchers

 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.