nypublicradio / nypr-toolkit

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

NYPR Toolkit

The NYPR Toolkit site provides a interface for customizing engagement modules.

Static Content

Templates can be found in apps/templates/. The text is rendered using a version of Markdown called CommonMark.

See here for more info on the CommonMark syntax

Development

Clone the repo.

$ git clone git@github.com:nypublicradio/nypr-toolkit.git

Switch to the directory.

$ cd nypr-toolkit

Install dependencies.

$ npm install
$ bower install

To develop interactively with other modules, you'll need to add URLs that point to live instances of each module. You can point to the demo versions or spin up local copies and point to those.

First make an env file. The sample file will point to the demo environment for each module.

$ cp .env.sample .env

Start a local server.

$ ember serve

You can now visit the app at http://localhost:4200 in a browser.

Modules

The toolkit site will embed configurable instances of the following static apps:

Each of these has their own corresponding envvar which points at a running instance (described above).

Prerequisites

You will need the following things properly installed on your computer.

Running Tests

  • ember test
  • ember test --server

Deploying

Deployment is handled by circle. Commits to master will deploy to the demo environment (i.e. https://demo-apps.nypr.org/toolkit). Tagged commits will deploy to the production environment.

Environment Variables

Name Default Description
AWS_BUCKET '' Destination bucket for deploys
AWS_PREFIX '' Path prefix for deployed assets
AWS_REGION '' AWS Region for infrastructure
AWS_ACCESS_KEY_ID '' AWS access key id
AWS_SECRET_ACCESS_KEY '' AWS secret access key
CALL_TO_ACTION https://demo-apps.nypr.org/call-to-action/ call-to-action url
NEWSLETTER_SIGNUP https://demo-apps.nypr.org/newsletter-signup/ newsletter-signup url
ADMIN_ROOT https://internal.demo2.wnyc.net Used by nypr-auth to authenticate users against the publisher microservice
MAILCHIMP_PROXY https://api.demo.nypr.digital/mailchimp-proxy Used by the newsletter interface to offer a list of Mailchimp newsletters

Further Reading / Useful Links

About


Languages

Language:JavaScript 64.4%Language:Handlebars 23.5%Language:SCSS 10.2%Language:HTML 1.9%