Skip to content

ryanbmarx/superweeds

Repository files navigation

Glyphosate-resistant weeds

A Tarbell project.

Assumptions

Custom configuration

DEFAULT_CONTEXT['OMNITURE']

This project uses python-tribune-omniture to render the Omniture <script> tags for the Tribune's analytics. You'll need to configure the dictionary named OMNITURE in the DEFAULT_CONTEXT dictionary in your tarbell_config.py:

DEFAULT_CONTEXT = {
    'name': 'lead',
    'title': 'Lead',
    'analytics_path': '',
    'OMNITURE': {
        'domain': 'chicagotribune.com',
        'sitename': 'Chicago Tribune',
        'section': 'news',
        'subsection': 'watchdog',
        'subsubsection': '',
        'type': 'dataproject',
    },
}

Building front-end assets

This project uses Grunt to build front-end assets.

To compile CSS and JavaScript for this project, first install the build tool depenencies:

npm install

When you run:

grunt

Grunt will compile sass/styles.scss into css/styles.css and bundle/minify js/src/app.js into js/app.min.js.

If you want to recompile as you develop, run:

grunt && grunt watch

The blueprint simply sets up the the build tools to generate styles.css and js/app.min.js, you'll have to explicitly update your templates to point to these generated files. The reason for this is to make you think about whether you're actually going to use an external CSS or JavaScript file and avoid a request for an empty file if you don't end up putting anything in your custom stylesheet or JavaScript file.

To add styles.css, add this to your template file (likely, index.html):

<link rel="stylesheet" href="css/styles.css">

To add app.min.js to your template file:

<script src="js/app.min.js"></script>

About

For an investigative story on the rise of weedkiller-resistant weeds, I made code-based animations (with illustrator Rick Tuma) and graphics showing how weeds learn to resist.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published