Code Monkey home page Code Monkey logo

numenta.org's Introduction

NuPIC Website Sourcecode

This is the open source code for the NuPIC Website hosted at http://numenta.org

Build Status

Tech Stack

Client

  • Web Platform:
    • HTML5 markup semantic page structure
      • HTML pages are found in ./**/*.html
        • These pages are wrapped in layout templates found in ./_layouts/
        • These pages pull in partial include templates from ./_includes/
          • Pages and Includes will load and render Markdown .md text content from the ./_includes/content/ directory
      • Final output is generated and served from the ./_site/ directory
    • CSS3 styling with SASS preprocessing
      • Pages load CSS from the ./assets/css/ directory.
        • These files originate as .scss SASS files
          • The SASS files include template partials from the ./_sass/ directory
    • JS functionality
  • jQuery dom helper lib
  • Bootstrap responsive frontend framework

Server

Build

Prerequisites

Example of a quick Mac OS X setup:

brew install git ruby node
git clone [email protected]:numenta/numenta.org.git
cd numenta.org
gem install bundler
bundle install
npm install

Development

Build and Serve local dev site:

npm run dev

View local development site:

http://localhost:4000

Test by starting up a dev webserver on default port (8008) and run webtests and linkchecks against local environment:

# use defaults
npm run test

# customize test target if needed (defaults listed)
TEST_HOST=http://localhost TEST_PORT=8008 TEST_PATH=  npm run test

Staging

Build:

  • Modify _config.yml and set baseurl to be /numenta.org
  • Push changes to your own github username/gh-pages branch
  • Note: Living Styleguide doesn't work fully on Staging yet, it doesn't know about the gh-pages Jekyll baseurl setting.

View: Your own staging site will build and be available:

http://username.github.io/numenta.org/

Test against your Staging:

TEST_HOST=http://username.github.io TEST_PORT=80 TEST_PATH=/numenta.org npm run test

Production

Build:

View: Production build is available at the main URL:

http://numenta.org

Test against Production:

TEST_HOST=http://numenta.org TEST_PORT=80 TEST_PATH=  npm run test

Best Practices

Content

  • Markdown Text Content:
    • Main content text is stored as markdown here: _includes/content/
      • Quick snippet to load a Markdown text block:
        • {% include base/markdown.html file='text.md' %}
  • Links:
    • Social Sharing link URLs do not have full hostnames when in Development or Staging, but they will be full in Production.
    • DO NOT forget to include the {{ site.baseurl }} template variable on internal links.
      • If you forget to use it, you will break staging sites.
    • Use & instead of & within links.
      • (Local Jekyll may run fine, but GitHub Pages may die without warning.)

Design

  • Living Styleguide
  • Clean, Simple, Modern, Intelligent style
  • Mobile First
  • Standards-compliant as possible
  • Support a wide array of users with accessibility needs
  • Retina images automatically loaded via Retina.js - for image.png, expects a 2x resolution file named [email protected]

Development

  • Keep Standards-compliant as possible
  • Support a wide array of users with accessibility needs
  • Node Style: 2 space text file indentation, 80-width text files, etc.
  • Clean simple file and directory names, no spaces (please use dash "-" instead) with lowercase and alphanumeric characters.
  • Keep local dev Ruby gems updated: bundle update
  • Modules:
    • node_modules meant for inclusion by the browser (jquery, bootstrap, etc) are stored in source control, and copied to _site/node_modules on build, where the browser can get to them.
    • node_modules not meant for the frontend (devDependencies, etc) should be ignored in .gitignore and _config.yml.

numenta.org's People

Contributors

arlolra avatar brev avatar carlfriess avatar cbaranski avatar cogmission avatar csimons avatar iandanforth avatar jefffohl avatar numenta-ci avatar oxtopus avatar passiweinberger avatar rcrowder avatar rhyolight avatar scottpurdy avatar utensil avatar willperkins avatar

Watchers

 avatar  avatar

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.