ig.news is a blog about ReactJs developed in the Ignite Bootcamp by RocketSeat.
These instructions will get you a copy of the full project up and running on your local machine for development and testing purposes.
The project must be built with npm, so download it below if you don't have any installed on your system.
-
Npm is distributed with Node.js which means that when you download Node.js, you automatically get npm installed on your computer. Download Node.js
-
Yarn is a package manager built by Facebook Team and seems to be faster than npm in general. Download Yarn
To run this server you will need a node version 12.0.0 (minimum)
This project uses Stripe api as Payment sistem so you'll neeed to create a Stripe account with a Product registred.
Stripe CLI is a tools to recive stripe webhooks in development environment. To install follow the documentation.
After you must run the following command in terminal to start to listen the webhooks:
$ stripe listen --forward-to localhost:3000/api/webhooks
Finally you must add this lines to .env.local
file:
STRIPE_API_KEY= // Api key
NEXT_PUBLIC_STRIPE_PUBLIC_KEY= // Public key
STRIPE_WEBHOOK_SECRET= // Webhook signing secret
STRIPE_SUCCESS_URL=http://localhost:3000/posts
STRIPE_CANCEL_URL=http://localhost:3000/
Prismic is a Content Management System, a tool for editing online content.
You must create a account and a new Type Post
whith this format:
You need to create a private key for your prismic repository. Go to Settings > API & Security > Repository ecurity
and select 'Private API'.
Finally you must add this line to .env.local
file:
PRISMIC_API_ENDPOINT= // Api endpoint
PRISMIC_ACCESS_TOKEN= // Api secret token
FaunaDB is a flexible transactional database delivered as a secure and scalable cloud API with native GraphQL
You must create a account and a new database Post
whith this collections and Indexes:
You must to create a private key to acess your fauna database. Go to Security > Keys > + New Key
and select 'Private API'.
Finally you must add this line to .env.local
file:
FAUNADB_KEY= // Api secret key
- To download the project follow the instructions bellow:
-
git clone https://github.com/italoh623/ignews.git
-
cd ignews
- Install the dependencies and start the server:
-
yarn install
-
yarn start
🥳
- Home Page
- Posts Page
- Post Preview Page
The application still is in development 🚧. Soon this file will be updated with the deploy of the app and new features
Ítalo Henrique Leça da Silva