Additional details to supplement the brief nature of the README file.
Fuel UX can be applied to a section of your your HTML or the entire page by adding the fuelux
wrapper class (eg. checkbox):
<body class="fuelux">
<!-- .... -->
<div class="checkbox">
<label class="checkbox-custom" data-initialize="checkbox" id="myCustomCheckbox">
<input class="sr-only" type="checkbox" value="">
<span class="checkbox-label">Custom checkbox unchecked on page load</span>
</label>
</div>
<!-- .... -->
</body>
Fuel UX can be obtained in any of the following ways:
bower install fuelux
Update with bower update fuelux
.
volo add fuelux
Update with volo add -f fuelux
.
git clone https://github.com/ExactTarget/fuelux/
Cloning the repository ensures you can apply future updates to Fuel UX easily, but requires to you manage its dependencies on your own.
We recommend only loading the controls you need (eg fuelux/checkbox
).
If using AMD (such as RequireJS), reference the FuelUX directory in your paths configuration, wherever it is located:
require.config({
paths: {
'fuelux': 'http://www.fuelcdn.com/fuelux/3.6.4/'
//...
}
});
Then list any individual fuel ux controls needed as dependencies within your application modules:
define(function(require) {
var spinbox = require('fuelux/spinbox');
//...
});
In instances where you require every module from Fuel UX, you can use fuelux/all
instead of listing each module individually.
Fuel UX also supports placing components in their own <script>
tags. Be sure to check component dependencies in the controls documentation and put modules in the correct order if you load them in this method. Errors will appear in the console if you have not loaded dependencies correctly ((Repeater)[http://getfuelux.com/javascript.html#repeater-dependencies] and Scheduler are the only components with dependencies currently).
Fuel UX is lightweight to give you a fast dependable foundation to build upon. It uses Grunt with convenient methods for working with the library. It's how we compile our code, run tests, and more. To use it, install the required dependencies as directed, and then run some Grunt tasks.
From the command line:
grunt-cli
globally with npm install -g grunt-cli
.npm install
. npm will look at package.json and automatically install the necessary local dependencies listed there.When completed, you'll be able to run the various Grunt commands provided from the command line.
Unfamiliar with npm? Don't have node installed? npm stands for node packaged modules and is a way to manage development dependencies through node.js. Download and install node.js before proceeding.
Run grunt --help
or check out the Gruntfile to see all possible grunt tasks. When contributing, these are the grunt tasks you will be most likely to use:
grunt
Runs JSHint and full suite of QUnit tests.
grunt serve
Starts a watch server for automated javascript validation and basic tests (JSHint, simplified QUnit) allowing for visual review of tests at http://localhost:8000/test/.
grunt release
If you have forked the repo for personal use, you will also find this task useful.
This builds the dist directory (compiling your CSS and JS). If you are going to issue a pull request, you should not include changes to the dist directory that are generated from this grunt task.
Should you encounter problems with installing dependencies or running Grunt commands, uninstall all previous dependency versions (global and local). Then, rerun npm install
.
gem install rouge
./fuelux
directory, run jekyll serve
in the command line.Learn more about using Jekyll by reading its documentation.
Giving credit where credit is due.
Pull requests are validate via Travis CI.
Periodically pull requests may fail Travis CI build integration testing with a false negative. If you suspect this is the case you can restart the test via the command line.
Travis downloads the node_modules
folder from the "Edge" server ("fuelux-dev") hosted on Heroku. If you add or update a dependency in package.json
, you will need to also update package.json
in master
locally and push it to Heroku for the dependency errors to be resolved in Travis.
Travis requires ruby and the appropriate ruby gem.
travis login --org
Acquire build number In the terminal, issue the following command:
travis history
Restart Build using the build number you obtained from travis history
In the terminal, issue the following command:
travis restart 9999
We have an "Edge Server" on Heroku named "fuelux-dev". If you have permissions to the ExactTarget org on Heroku, you can get information on cloning the fuelux-dev
remote from its app page on Heroku. If you do not have permissions and believe you should, please contact one of the FuelUX project maintainers.
A build of master is available at https://fuelux-dev.herokuapp.com/dist/js/fuelux.js
and https://fuelux-dev.herokuapp.com/dist/css/fuelux.css
.
These files should be considered unstable as this is our dev server
To create your own edge server, setup a github web hook on Heroku for this repository and put the app into development mode with heroku config:set NPM_CONFIG_PRODUCTION=false
.