Hello there! This repo is a home to Pixel Point, a web agency that designs and develops world-class marketing websites. We made this codebase available to open source community so everyone can get something useful out of our expertise, be it for project structure, code patterns or plugins.
Below you will find some basic information about how to work with this project. If you've spotted a bug, a copywriting mistake or just want to suggest some better solution, please, refer to the contribution section.
- Clone repository
git clone git@github.com:pixel-point/pixelpoint-website.git
- Install dependencies
npm install
- Add
.env
file
cp .env.example .env
npm run start
npm run build
npm run serve
npm run clean
├── content
│ ├── case-studies
│ └── posts
├── src
│ ├── components
│ │ ├── pages — React components that are being used specifically on a certain page
│ │ └── shared — React components that are being used across the whole website
│ ├── constants
│ ├── hooks
│ ├── images
│ ├── pages
│ ├── styles
│ ├── templates
│ ├── utils
│ └── html.jsx
├── static
│ ├── animations
│ │ ├── pages — Rive animation files that are being used specifically on a certain page
│ │ └── shared — Rive animation files that are being used across the whole website
│ ├── fonts
│ └── images
├── gatsby-browser.js
├── gatsby-config.js
├── gatsby-node.js
├── gatsby-ssr.js
└── tailwind.config.js
- Main JavaScript File
- Index File
- Folder with images and icons
- Folder with data
Also, each component may include another component that follows all above listed rules.
component
├── nested-component
│ ├── data
│ │ └── nested-component-lottie-data.json
│ ├── images
│ │ ├── nested-component-image.jpg
│ │ ├── nested-component-inline-svg.inline.svg
│ │ └── nested-component-url-svg.svg
│ ├── nested-component.js
│ └── index.js
├── data
│ └── component-lottie-data.json
├── images
│ ├── component-image.jpg
│ ├── component-inline-svg.inline.svg
│ └── component-url-svg.svg
├── component.js
└── index.js
ESLint helps find and fix code style issues and force developers to follow same rules. Current configuration is based on Airbnb style guide.
Additional commands:
npm run lint
Run it to check the current status of eslint issues across project.
npm run lint:fix
Run it to fix all possible issues.
Prettier helps to format code based on defined rules. Difference between Prettier and ESLint.
Additional commands:
npm run format
Run it to format all files across the project.
Following extensions required to simplify the process of keeping the same code style across the project:
After installation enable "ESLint on save" by adding to your VS Code settings.json the following line:
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
}
You can navigate to settings.json by using Command Pallete (CMD+Shift+P) and then type "Open settings.json".
To enable Prettier go to Preferences -> Settings -> type "Format". Then check that you have esbenp.prettier-vscode as default formatter, and also enable "Format On Save".
Reload VS Code and auto-format will work for you.
In order to generate a poster for a video you can use ffmpeg tool. Modify 00:00:01.000
timecode option to get a desired poster quality.
ffmpeg -i https://pixel-point-website.s3.amazonaws.com/posts/2022-06-20-motion-morning-3/9.mp4 -ss 00:00:01.000 -vframes 1 video-cover-1.jpg
Contribution is highly welcomed!
If there is a bug you've encountered, an occasional typo or just want to ask something, don't hesitate to raise and issue or even make a PR.
There are no special contribution guidelines, just use your common sense, keep your changes cohesive with the overall code style and leverage the project info above.
When raising an issue or making a pull request, please do use appropriate labels.
Thank you!
All assets and code are under the MIT LICENSE and in the public domain unless specified otherwise.
The client logos are trademarks of their respective companies and are under their terms and license.