Are you happy with your logging solution? Would you help us out by taking a 30-second survey? Click here

FoundationPress

FoundationPress is a WordPress starter theme based on Foundation 6 by Zurb

Subscribe to updates I use FoundationPress


Statistics on FoundationPress

Number of watchers on Github 2585
Number of open issues 41
Average time to close an issue 10 days
Main language PHP
Average time to merge a PR 1 day
Open pull requests 17+
Closed pull requests 33+
Last commit over 1 year ago
Repo Created almost 6 years ago
Repo Last Updated over 1 year ago
Size 10.1 MB
Homepage https://foundatio...
Organization / Authorolefredrik
Latest Releasev2.10.4
Contributors63
Page Updated
Do you use FoundationPress? Leave a review!
View open issues (41)
View FoundationPress activity
View on github
Fresh, new opensource launches 🚀🚀🚀
Trendy new open source projects in your inbox! View examples

Subscribe to our mailing list

Evaluating FoundationPress for your project? Score Explanation
Commits Score (?)
Issues & PR Score (?)

FoundationPress

Gitter GitHub version license Buy Me a Coffee at ko-fi.com

This is a starter-theme for WordPress based on Zurb's Foundation for Sites 6, the most advanced responsive (mobile-first) framework in the world. The purpose of FoundationPress, is to act as a small and handy toolbox that contains the essentials needed to build any design. FoundationPress is meant to be a starting point, not the final product.

Please fork, copy, modify, delete, share or do whatever you like with this.

All contributions are welcome!

Requirements

This project requires Node.js v4.x.x to v6.11.x to be installed on your machine. Please be aware that you might encounter problems with the installation if you are using the most current Node version (bleeding edge) with all the latest features.

FoundationPress uses Sass (CSS with superpowers). In short, Sass is a CSS pre-processor that allows you to write styles more effectively and tidy.

The Sass is compiled using libsass, which requires the GCC to be installed on your machine. Windows users can install it through MinGW, and Mac users can install it through the Xcode Command-line Tools.

If you have not worked with a Sass-based workflow before, I would recommend reading FoundationPress for beginners, a short blog post that explains what you need to know.

Quickstart

1. Clone the repository and install with npm

$ cd my-wordpress-folder/wp-content/themes/
$ git clone https://github.com/olefredrik/FoundationPress.git
$ cd FoundationPress
$ npm install

2. Configuration

YAML config file

FoundationPress includes a config-default.yml file. To make changes to the configuration, make a copy of config-default.yml and name it config.yml and make changes to that file. The config.yml file is ignored by git so that each environment can use a different configuration with the same git repo.

At the start of the build process a check is done to see if a config.yml file exists. If config.yml exists, the configuration will be loaded from config.yml. If config.yml does not exist, config-default.yml will be used as a fallback.

Browsersync setup

If you want to take advantage of Browsersync (automatic browser refresh when a file is saved), simply open your config.yml file after creating it in the previous step, and put your local dev-server address and port (e.g http://localhost:8888) in the url property under the BROWSERSYNC object.

Static asset hashing / cache breaker

If you want to make sure your users see the latest changes after re-deploying your theme, you can enable static asset hashing. In your config.yml, set REVISIONING: true;. Hashing will work on the npm run build and npm run dev commands. It will not be applied on the start command with browsersync. This is by design. Hashing will only change if there are actual changes in the files.

3. Get started

$ npm start

4. Compile assets for production

When building for production, the CSS and JS will be minified. To minify the assets in your /dist folder, run

$ npm run build

To create a .zip file of your theme, run:

$ npm run package

Running this command will build and minify the theme's assets and place a .zip archive of the theme in the packaged directory. This excludes the developer files/directories from your theme like /node_modules, /src, etc. to keep the theme lightweight for transferring the theme to a staging or production server.

Project structure

In the /src folder you will the working files for all your assets. Every time you make a change to a file that is watched by Gulp, the output will be saved to the /dist folder. The contents of this folder is the compiled code that you should not touch (unless you have a good reason for it).

The /page-templates folder contains templates that can be selected in the Pages section of the WordPress admin panel. To create a new page-template, simply create a new file in this folder and make sure to give it a template name.

I guess the rest is quite self explanatory. Feel free to ask if you feel stuck.

Styles and Sass Compilation

  • style.css: Do not worry about this file. (For some reason) it's required by WordPress. All styling are handled in the Sass files described below

  • src/assets/scss/app.scss: Make imports for all your styles here

  • src/assets/scss/global/*.scss: Global settings

  • src/assets/scss/components/*.scss: Buttons etc.

  • src/assets/scss/modules/*.scss: Topbar, footer etc.

  • src/assets/scss/templates/*.scss: Page template styling

  • dist/assets/css/app.css: This file is loaded in the <head> section of your document, and contains the compiled styles for your project.

If you're new to Sass, please note that you need to have Gulp running in the background (npm start), for any changes in your scss files to be compiled to app.css.

JavaScript Compilation

All JavaScript files, including Foundation's modules, are imported through the src/assets/js/app.js file. The files are imported using module dependency with webpack as the module bundler.

If you're unfamiliar with modules and module bundling, check out this resource for node style require/exports and this resource to understand ES6 modules.

Foundation modules are loaded in the src/assets/js/app.js file. By default all components are loaded. You can also pick and choose which modules to include. Just follow the instructions in the file.

If you need to output additional JavaScript files separate from app.js, do the following:

  • Create new custom.js file in src/assets/js/. If you will be using jQuery, add import $ from 'jquery'; at the top of the file.
  • In config.yml, add src/assets/js/custom.js to PATHS.entries.
  • Build (npm start)
  • You will now have a custom.js file outputted to the dist/assets/js/ directory.

Demo

Local Development

We recommend using one of the following setups for local WordPress development:

Resources

Tutorials

Documentation

Showcase

Credit goes to all the brilliant designers and developers out there. Have you made a site that should be on this list? Please let me know

Contributing

Here are ways to get involved:

  1. Star the project!
  2. Answer questions that come through GitHub issues
  3. Report a bug that you find
  4. Share a theme you've built on top of FoundationPress
  5. Tweet and blog your experience of FoundationPress.

Pull Requests

Pull requests are highly appreciated. Please follow these guidelines:

  1. Solve a problem. Features are great, but even better is cleaning-up and fixing issues in the code that you discover
  2. Make sure that your code is bug-free and does not introduce new bugs
  3. Create a pull request
  4. Verify that all the Travis-CI build checks have passed
FoundationPress open issues Ask a question     (View All Issues)
  • almost 3 years Is FoundationPress Updated?
  • almost 3 years Compilation issue
  • almost 3 years .active class applied to .main-menu li when using custom relative URLs in Menus
  • almost 3 years jQuery error from 'source' folder
  • about 3 years Sudden error when running "npm run watch"
  • about 3 years Linking to an anchor tag on different post/page prevents scrolling up
  • about 3 years node.js
  • about 3 years How to make pre_get_posts to work (to avoid using query_posts)?
  • about 3 years is_single returns true for attachment page (navigation.php)
  • about 3 years Error: Cannot find module 'sparkles'
  • about 3 years Error during npm run build
  • about 3 years How to make dropdowns in main nav open right
  • over 3 years Buddypress
  • over 3 years WP built-in post tags
  • over 3 years Is FP compatible with the WP Theme Directory guidelines?
  • over 3 years Theme Check Errors - Should I Be Worried?
  • over 3 years Post Nav/Pagination Not Showing
  • over 3 years Maybe add node version somewhere at first install?
  • over 3 years $foundation-palette: Not compiling
  • over 3 years Active dropdown always showing.
  • over 3 years data-equalize-on not working
  • over 3 years using xlarge and xxlarge causes warnings
  • over 3 years SCSS Compiling Issue / Components Not Importing
  • over 3 years Should Aside be used for the sidebar?
  • over 3 years Npm run / build 'clean' javascript error - Gulp/Node/Windows 7 Dependencies
  • over 3 years Navigation dropdown always open
  • over 3 years npm run production watches files
  • over 3 years Woocommerce template overrides
  • over 3 years Modify topbar to accordion menu
  • over 3 years cant click parent links in Off-Canvas Navigation
FoundationPress open pull requests (View All Pulls)
  • Responsive images
  • The search takes priority over categories
  • Change off-canvas menu height to affect all menus
  • remove favicon
  • For correct compiling of scss
  • Switch to gulp-clean-css from deprecated gulp-minify-css
  • Bugfix for figure tag
  • express pawn repo opened
  • Remove executable permissions for files
  • Updated README.md with info on packaging the theme to a zip file
  • Simple fixes
  • Responsive accordion tabs
  • translate(urdu): mo, po file
  • Wordpress gallery: Added css and custom markup
  • Update package-lock.json file to sync up with package.json .
  • update jqmigrate to be compatible with jquery version used
  • Fix image alignment bug discussed in #1237.
FoundationPress questions on Stackoverflow (View All Questions)
  • FoundationPress start
  • FoundationPress: want to add task to Gruntfile.js
  • FoundationPress Couldn't delete file: Failure in sftp
  • foundation sticky Offcanvas menu not working with foundationpress theme
  • My customized javascript is not working in Foundationpress
  • Grunt, Compass, Foundation (foundationpress wordpress theme)
FoundationPress list of languages used
FoundationPress latest release notes
v2.10.4 FoundationPress v2.10.4

v2.10.4 (2017-10-11)

Full Changelog

Fixed bugs:

  • WooCommerce Sidebar issues #1057

Closed issues:

  • Responsive $grid-margin-gutters only work when XY-cell is included with a breakpoint #1121
  • Basic grid not working? #1117
  • Saving php file causes loss of sass changes in BrowserSync #1113
  • Where do I put JS files so they are added to the /dist/ folder? #1108
  • Old NPM run build method..... #1107
  • Override WooCommerce styles #1106
  • check-if-sidebar-exist.php Is this used anymore? #1103
  • XY Grid offsets don't include margin or padding #1099
  • Removing before and after hooks... #1097
  • Sticky Footer JS Missing #1095
  • Content in Single.php #1094
  • error on npm start #1093
  • Error While npm install -g gulp #1092
  • Semantically incorrect use of article elements #1091
  • Npm start error #1089
  • Breadcrumbs error (custom post types/taxonomies) #1088
  • Pagination showing same content #1087
  • Update configuration process #1083
  • Remove woocommerce hooks in cleanup.php.. #1082
  • Article elements for widgets in sidebar and footer.. #1078
  • How to get the breakpoint variable value from _settings.scss #1077
  • Conflict with Gravityforms - jQuery is not defined #1076
  • Stick with 2.9 or tweak 2.10 for compatibility? #1075
  • Error in plugin: 'sass' after changing values in _settings.scss #1074
  • Stop combine admin enqueue JavaScript into one file or add ignore options #1073
  • Dropdown Links Not Working - Tablet #1072
  • Add javascript file #1069
  • WooCommerce 3.0 - Hidden products showing in search results #1068
  • Rename & fix path file #1067
  • missing textdomains #1066
  • Npm start not watching css modifications #1064
  • template-specific sass styles #1062
  • #footer-container Issues #1060
  • Console error: Uncaught SyntaxError: Unexpected token import #1051
  • WP built-in post tags #851

Merged pull requests:

v2.10.3 FoundationPress v2.10.3

v2.10.3 (2017-08-29)

Full Changelog

Fixed bugs:

  • Issue with WooCommerce 3.0 new Gallery #1043
  • Active class no longer being applied to Topbar link on active page #933
  • .active class applied to .main-menu li when using custom relative URLs in Menus #914
  • cant click parent links in Off-Canvas Navigation #710

Closed issues:

  • Installation issue #1055
  • Grid elements don't function #1054
  • app.js not building? #1053
  • Issues with running jQuery 3.x #1052
  • What version of FoundationPress & Foundation am I running? #1050
  • $offcanvas-size is deprecated #1048
  • Tracking in git? #1047
  • npm run command not working after running npm build #1046
  • I'm not sure how to Package #1045
  • Keeping customizer settings when packaging / deploying the theme #1044
  • Error with npm run package #1042
  • Manage packaging #1039
  • syntax error navigation.php on line 131 #1035
  • How to import 3rd party css? #1034
  • .main-wrap causing horizontal scrolling on breakpoints #1029
  • Has the update changed how the grid works? #1026
  • Issue installing FoundationPress #1020
  • Revisioned assets for gulp --production #944
  • disable off-canvas menu #930
  • Linking to an anchor tag on different post/page prevents scrolling up #887
  • Post Nav/Pagination Not Showing #820
  • Motion UI and WP sub-menus #701
  • [Shortcodes] [Buttons] #694
  • Problem with Custom Menu widget #621
  • Improve Documentation #605
  • Foundation Shortcode Buttons In WYSIWYG Editor #599
  • Display Header Text Checkbox Not Displaying in Customizer #464

Merged pull requests:

v2.10.2 FoundationPress v2.10.2

v2.10.2 (2017-08-08)

Full Changelog

Fixed bugs:

  • Active class no longer being applied to Topbar link on active page #933
  • .active class applied to .main-menu li when using custom relative URLs in Menus #914

Closed issues:

  • Missing script: watch #1028
  • Smooth Scroll not added. #1027
  • Foundation 6.4.0 #1008
  • WooCommerce 3.0 Compatibility (New Zoom/Lightbox feature) #991
  • WooCommerce compatibility #982
  • Main menu with dropdowns - tapping sub-item link in iOS closes menu, does nothing else #975
  • responsive toggle menu stops working on 6.3.1 #973
  • Duplicate search bar when widget search produces no results #970
  • Dropdown menu issue #969
  • Header is covering top menu #938
  • How to make dropdowns in main nav open right #862
  • Theme Check Errors - Should I Be Worried? #840
  • Woocommerce template overrides #718
  • foundationpress_before_content function not implemented #601
  • No rss/atom link? #566
  • Stupid Question - how to set menu order to follow page order #541
  • Move right menu under left menu? #531

Merged pull requests:

Other projects in PHP