Skip to content

dentemple/NEPAjs-website

 
 

Repository files navigation

NEPA.js styled with prettier License: MIT

PRs welcome. Feel free to contribute!

Website for the NEPA.js Meetup Group, a community of JavaScript enthusiasts serving Northeast Pennsylvania.

Join our next Meetup Group!

Find us on Twitter!

Code of Conduct

Read our Code of Conduct.

Project Technology

Configuration has been bootstrapped with Create React App.

Install and Contribute

Required

  • Node.js (recommended v6.0 and above)
  • yarn
  • A terminal interface (such as git bash for Windows users)

Run locally

  • Clone the repository -- git clone git@github.com:nepajs/website.git nepajs-website
  • Navigate into the new folder -- cd nepajs-website
  • Install the project's dependencies -- yarn
  • Run the client in dev mode -- yarn start
  • The browser will navigate to http://localhost:3000.

No need to think about code style

Prettier will automatically convert your code to fit the project's style guide.

This occurs on every git commit.

For the best experience, integrate Prettier into your editor of choice.

API keys

Certain components may require special passwords to function.

Required APIs:

These keys should NOT be saved into Github. To help prevent this, a template file has been created for you.

  • Create an account at the link(s) above, and generate your personal API key(s)
  • Navigate to the file /src/util/ folder and look for /SECRET.example.js
  • Make a copy of this file and name it to /SECRET.js
  • Replace the example keys with your actual API keys
  • Save your API keys to this new /SECRET.js file
  • DO NOT save your API keys to the original /SECRET.example.js file

.gitignore will prevent /SECRET.js from publishing these keys to Github.

Add new tests

Documentation for Jest and Enzyme testing.

  • All test files are kept in folders named __tests__
  • Naming convention: <Name of original file>.test.js
  • Run the test suite -- yarn test
  • Update the UI snapshots -- yarn test:update
    • The __snapshots__ folders don't need to be adjusted manually
  • Run a coverage report -- yarn test:coverage

Make sure there are no failing tests prior to sending us a Pull Request!

Send us your changes

Additional Information

Project Hierarchy

The main client-side code can be found in the src/ directory

  • Entry point/render: src/index.js
  • Routing: src/App.jsx
  • A service worker has been installed as per the PWA specification
    • This service worker is part of Create React App and shouldn't need to be updated

"Top-level" components can be found in the src/page directory.

  • Currently, there is no practical difference between src/page and src/component
  • In the future, these top-level components may be rendered server-side

All other components can be found in the src/component directory.

  • Related files that execute a single function are grouped together into the same sub-directory
    • i.e. All files that to serve to create the HeroImage (such as its main React component, its test files, and its .jpg image) will be found in the src/component/HeroImage/ sub-directory
  • The "master" file within these sub-directories are named index.js[x]

Special/unique files can be found in the src/util directory.

License

MIT

About

A community of JavaScript enthusiasts for Northeastern Pennsylvania

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 98.9%
  • HTML 1.1%