To run this project locally:
git clone [email protected]:alulsh/family-tree-map.git
cd family-tree-map
npm install
npm run dev
This will start a Parcel development server in watch mode at http://localhost:1234.
This project uses the following production dependencies:
- Mapbox GL JS for maps
- Mapbox Geocoding API for geocoding
- gedcom for parsing GEDCOM files
- dayjs for parsing dates from GEDCOM files
- jQuery DataTables for displaying processed family tree results
- Assembly.css for CSS
- Parcel for bundling npm packages for the browser
Run npm test
to run tests locally. This project runs tests automatically on every commit using GitHub Workflows.
This project uses Jest for tests with a minimal Babel configuration for compatibility with Parcel. Since this project loads Mapbox GL JS through the Mapbox CDN instead of bundling with Parcel, the Jest tests mock Mapbox GL JS using the global object in the test set up file.
This project uses eslint with the Airbnb JavaScript style guide for code quality and Prettier for code formatting.
If you're using Visual Studio Code, you can add the following to your .vscode/settings.json
file for this project to enable automatic linting and formatting on save:
{
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
}
This project is hosted on GitHub Pages using the gh-pages
branch. Parcel bundles all files to a local dist
directory, which we push to the gh-pages
branch. You can view the deployment at https://www.alexandraulsh.com/family-tree-map/.
This project runs the npm run build
command automatically on every commit using GitHub Workflows to catch any potential build errors.
To deploy updates to GitHub Pages:
npm run build
npm run deploy