Code Monkey home page Code Monkey logo

mets-misery-index's Introduction

Inspired by and based on the Denver Post’s Rockies Misery Index

Production

In-article widgets

Here's the new workflow for adding a Mets Misery Index widget to articles:

  1. Go to https://github.com/nydailynews/mets-misery-index#in-article-widgets . That will take you to the part of the page where the markup is for each of the three widgets: misery-injury, misery-poll and misery-index.
  2. Choose which of the three widgets you want and triple-click the line with that markup.
  3. You should have the line with the markup selected now. Copy it to your clipboard.
  4. In SNAP, edit the article you want to add the widget to. Then:
    1. Create a new HTML embed.
    2. Paste the contents of your clipboard into the field.
    3. It should look something like this:
<iframe id="misery-injury" scrolling="no" style="width: 100%; height: 310px; border: 0;" src="http://interactive.nydailynews.com/project/mets-misery-index/widget-injury-tracker.html"></iframe>

<iframe id="misery-poll" scrolling="no" style="width: 100%; height: 300px; border: 0;" src="http://interactive.nydailynews.com/project/mets-misery-index/widget-fan-misery.html"></iframe>

<iframe id="misery-index" scrolling="no" style="width: 100%; height: 190px; border: 0;" src="http://interactive.nydailynews.com/project/mets-misery-index/widget-misery.html"></iframe>

Usage

How to set up a dev environment

This is a python 3 app, make sure you have python 3 installed before continuing. brew install python3 on a mac.

  1. To create a virtual environment using python3, run something like mkvirtualenv --python=/usr/local/bin/python3 MISERY.
  2. cd to the project root
  3. pip3 install -r requirements.txt

If you don't have python 3 and virtualenv set up:

  1. brew install python3
  2. pip3 install virtualenv
  3. pip3 install virtualenvwrapper
  4. VIRTUALENVWRAPPER_PYTHON=/usr/local/bin/python3
  5. source /usr/local/bin/virtualenvwrapper.sh

mets-misery-index's People

Contributors

freejoe76 avatar kelliparker avatar

Watchers

 avatar  avatar  avatar  avatar

mets-misery-index's Issues

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.