• Stars
    star
    204
  • Rank 192,063 (Top 4 %)
  • Language
    CSS
  • License
    MIT License
  • Created almost 11 years ago
  • Updated over 7 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Yeoman generator for Zurb Foundation 5

generator-zf5

Yeoman generator for Zurb Foundation 5.

This project is not maintained anymore. There is Foundation for Sites 6 go and check it: foundation.zurb.com Also check out advanced starter project based on Gulp including Handlebars templates, UnCSS and many more: Foundation 6 Starter docs Also check out Getting Started with Foundation 6’s CLI Tools. Thanks!

Learn more about it (blog post):

Foundation 5 and Yeoman generator-zf5

Important note:

Default option here will be Sass with Libsass (for now). But you can choose Ruby version on startup.

NPM

NPM

Yo Foundation 5!

  • Sass compiling
  • autoprefixer (app.css file)
  • Publishing to dist directory
  • Server with LiveReload (127.0.0.1:9000)
  • Bower install
  • JSHint
  • Custom Modernizr build based on your features usage
  • Font Awesome (option)

Getting Started

$ npm install -g yo

To install generator-zf5 from npm, run:

$ npm install -g generator-zf5

Finally, initiate the generator:

$ yo zf5

Grunt tasks:

run project (compile Sass, bower install, livereload (server on 127.0.0.1:9000), watch)

$ grunt

publishing project (into dist directory) (compile Sass, validate-js, copy, concatenation, minifications)

$ grunt publish

dist directory preview (server on 127.0.0.1:9001)

$ grunt server-dist

Other Grunt tasks (if you want to use it)

..for validating javascript

$ grunt validate-js

..for injecting bower libraries (also in default grunt task)

$ grunt bower-install

..for compiling Sass files + autoprefixer on app.css file

$ grunt compile-sass

Ruby Sass with Compass or Node Sass (Libsass)

From version 0.7.0 you can use Ruby version of Sass with Compass. If you want to use Ruby version first of all you need to install compass by 'gem install compass' (it will install Sass gem too).

You don't need to use the config.rb file, all is configured in Gruntfile.js (Sass block). There will be also Compass imports in _appstyles.scss (You can modify it). If you have any problems with using Sass with Compass it is good to uninstall any of your Sass gems and Compass gems and install only Compass gem again. It will fetch proper version of Sass gem.

Ruby Sass config info: https://github.com/gruntjs/grunt-contrib-sass

You can also use Libsass version (default) which is very fast.

Node Sass config info: https://github.com/sindresorhus/grunt-sass

Please test this and send issues if any.

LiveReload

For LiveReload call 'grunt' (watching) command and go to http://127.0.0.1:9000

Usemin

Read more about grunt-usemin

Bower-install

Now you can install your libraries much faster. Example:

bower search magnific-popup
...
bower install magnific-popup --save
...
grunt bower-install

This should inject the proper js and css paths into your html files. But you should be careful and check what was injected. 'grunt publish' will then minify and concatenate them into a clean (libraries.min.css and libraries.min.js) files. Instead of a 'bower install' with '--save' you can manualy edit the bower.json file and then run a 'grunt bower-install'. It is also included in the default task - 'grunt'.

Tips

  • Sometimes after new version is released if you have errors when running yo zf5 You should run npm cache clean
  • If you have problems with permissions in Linux run this : sudo chown -R `whoami` ~/.npm
  • if you want you can delete not used javascript components in index.html file. All remaining components will be minified and concatenated into one foundation.min.js
  • if you have problems with connection to http://127.0.0.1:9000 change 'hostname' in Gruntfile.js 'connect' config. Just add hostname: '[your hostname]' line to options: {...}
  • if you want you can delete unnecessary/unused Foundation components from main app.scss (it will be lightest main Foundation css file)
  • place all your html files in the root folder (app) or you have to change assets paths (build etc.)
  • grunt useminPrepare reference file is only index.html (prevents multiple the same operations) but all html files will be processed, so remember to keep the same usemin 'comments blocks' in all your html files (for now it is good to simply copy index.html, rename it and leave header and footer css and js inclusions with 'comments blocks')
  • try to avoid situation when you have the same build blocks in two html files with different assets so (examples):
<!-- build:js js/mfpopup/mfpopup.min.js -->
    <script src="js/mfpopup/mfpopup.js"></script>
<!-- endbuild -->

and

<!-- build:css css/mfpopup/mfpopup.min.js -->
    <script src="js/mfpopup/mfpopup.js"></script>
    <script src="js/mfpopup/other_script.js"></script>
<!-- endbuild -->

you can add new ones

  • always verify what 'grunt bower-install' injects
  • You must look aut where you initialize your project. It is better to not initialize your projec in a subfolder next to .yo-rc.json because your files will land here and not in your subfolder from where you are initializing project
  • if you use Compass.. place your mixin includes after Foundation scss partials - more info (by default they are in _appstyles.scss)

You can test it and tell me please if something is not working.

Getting To Know Yeoman

Yeoman has a heart of gold. He's a person with feelings and opinions, but he's very easy to work with. If you think he's too opinionated, he can be easily convinced.

If you'd like to get to know Yeoman better and meet some of his friends, Grunt and Bower, check out the complete Getting Started Guide.

License

MIT License

Contact

@juliancwirko | [email protected]

Changelog

..see CHANGELOG.md file

More Repositories

1

react-s-alert

Alerts / Notifications for React with rich configuration options
JavaScript
649
star
2

react-npm-boilerplate

Boilerplate for creating React Npm packages with ES2015
JavaScript
235
star
3

s-chat-app

SimpleChat.Support - Open Source Live Chat App
HTML
231
star
4

meteor-s-alert

Simple and fancy notifications for Meteor
JavaScript
190
star
5

abc

Free theme for your Ghost blog
SCSS
172
star
6

scotty

Meteor React Redux boilerplate with Server-Side Rendering
JavaScript
151
star
7

react-boilerplate

React Boilerplate
JavaScript
125
star
8

nft-art-maker

NFT Art Maker - generates images and metadata files, packs them into IPFS CAR files, and uploads them using nft.storage. All from provided PNG layers.
TypeScript
98
star
9

react-redux-webpack-meteor

React demo app with Webpack, Redux and Meteor as a backend only
JavaScript
89
star
10

s-grid

Flexbox grid system for Stylus
CSS
64
star
11

react-s-alert-demo

Demo website for react-s-alert component
JavaScript
38
star
12

horizon-react-webpack-boilerplate

Horizon, React, Webpack boilerplate with demo app
JavaScript
35
star
13

create-harold-app

Static blog/site generator
JavaScript
35
star
14

meteor-s-grid

Stylus Flexbox grid system for Meteor with PostCSS and Autoprefixer included
JavaScript
28
star
15

s-grid-main-website

stylusgrid.com - source code
HTML
24
star
16

meteor-s-id

Simple accounts for Meteor.
JavaScript
19
star
17

meteor-bootstrap-postcss-test

Demo Meteor project which uses Bootstrap 4, Scss, PostCSS, Npm
JavaScript
15
star
18

elven.js

Authenticate, sign and send transactions on the MultiverseX (previously Elrond) blockchain in the browser. No need for bundlers, frameworks, etc. Just import from the static script source, and you are ready to go. One static file to rule it all on the MultiversX blockchain!
TypeScript
13
star
19

generator-jeet

Yeoman generator for Jeet Grid System
JavaScript
13
star
20

elrond-nft-minting-platform-poc

Elrond NFT minting platform POC (Also check out: www.elven.tools)
TypeScript
12
star
21

elven-mint

Script for automating minting NFTs on the Elrond blockchain (Also check out: www.elven.tools)
TypeScript
11
star
22

moralis-playground

Moralis playground - Moralis is a service that helps to build serverless web3 dApps.
JavaScript
10
star
23

meteor-zf5

Foundation 5 for Meteor
CSS
10
star
24

caprica-demo

Caprica - Meteor and Arduino - demo app
JavaScript
9
star
25

meteor-logo-website

Download customized Meteor logo
HTML
9
star
26

meteor-pretty-diff

Prettify and export your raw git diff output
JavaScript
8
star
27

meteor-npm-foundation-test

Foundation 6 from Npm with Meteor
CSS
8
star
28

generator-ziom

Angular + Bootstrap + Scss (Libsass) simple and custom Yeoman generator
JavaScript
7
star
29

meteor-bootstrap-npm-test

Bootstrap 4 from Npm with Meteor
JavaScript
7
star
30

meteor-s-jeet

Jeet (Stylus) grid system for Meteor. Especially for Scotty boilerplate.
JavaScript
6
star
31

meteor-css-modules-test

CSS Modules in Meteor.
JavaScript
6
star
32

meteor-schat-client-blaze

sChat client app for Meteor - Blaze view layer
CSS
6
star
33

meteor-pretty-diff-app

Working demo app for Meteor pretty-diff package
HTML
6
star
34

cra-template-elrond-dapp

Custom Elrond Dapp template for Create React App
TypeScript
5
star
35

smooth-scroll-top

Smooth scroll to top of the page
TypeScript
4
star
36

meteor-caprica

Simple admin template for juliancwirko:arduino-cylon package
JavaScript
4
star
37

meteor-s-image-box

Simple image popup/lightbox for Meteor
JavaScript
4
star
38

elvenjs-website

Website and docs for elven.js Elrond SDK
SCSS
3
star
39

meteor-arduino-cylon

Meteor and Cylon.js for Arduino
JavaScript
3
star
40

meteor-postcss-test

Test project with Meteor PostCSS package
HTML
3
star
41

cssnext-grunt-boilerplate

Grunt project starter with cssnext, Assemble and BrowserSync
CSS
3
star
42

live-chat-app-demo-html-client

Live Chat App - Static HTML Client Demo (blog post purposes)
JavaScript
3
star
43

meteor-schat-client-core

sChat client app for Meteor - core package
JavaScript
3
star
44

s-grid-grunt

Flexbox grid system - project scaffold with Stylus, Assemble and many useful Grunt tasks
HTML
2
star
45

meteor-s-id-website

Homepage for meteor-s-id
CSS
2
star
46

meteor-s-alert-website

Homepage for meteor-s-alert
CSS
2
star
47

relecheck

Track your favourite app updates on GitHub
2
star
48

juliancwirko

GitHub Profile
2
star
49

elrond-simple-sc-frontend-app

Frontend app for PiggyBank Smart Contract
TypeScript
2
star
50

meteor-s-alert-flip

Flip effect for s-alert - simple and fancy notifications for Meteor
CSS
2
star
51

multiversx-donate-widget-demo

MultiversX donate widget demo use case with elven.js
JavaScript
2
star
52

meteor-zf5-demo

Foundation 5 for Meteor - package's demo website
HTML
2
star
53

meteor-s-alert-genie

Genie effect for s-alert - simple and fancy notifications for Meteor
CSS
1
star
54

react-redux-rtk-example

TypeScript
1
star
55

gatsby-starter-netlify-test

JavaScript
1
star
56

s-alert-react-demo

Simple demo for sAlert Meteor package with React
JavaScript
1
star
57

vite-erdjs-test

Just playing around
TypeScript
1
star
58

arduino-temperature-logger

Arduino + Johnny Five temperature logger JavaScript app
JavaScript
1
star
59

cli-tool-starter

Starter for CLI tools written in Node
JavaScript
1
star
60

harold-website

create-harold-app website and documentation
SCSS
1
star
61

harold-template-scaffold

Scaffold for Harold custom templates
Handlebars
1
star
62

live-chat-app-demo-meteor-client

Live Chat App - Meteor Client Demo (blog post purposes)
JavaScript
1
star
63

harold-template-default

Default template for create-harold-app
Handlebars
1
star
64

harold-template-docs

Docs template for create-harold-app
SCSS
1
star
65

multiversx-node-hw-provider-poc

TypeScript
1
star
66

live-chat-app-demo-host

Live Chat App - Host Demo (blog post purposes)
JavaScript
1
star
67

meteor-s-alert-stackslide

Stackslide effect for s-alert - simple and fancy notifications for Meteor
CSS
1
star
68

chakra-typescript-problem

reproduction repository
TypeScript
1
star
69

harold-template-bare

Bare template for create-harold-app
Handlebars
1
star
70

harold-scripts

Harold Scripts for Create Harold App
JavaScript
1
star
71

harold-docs-template-demo

Harold docs template demo
SCSS
1
star