-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
97a3309
commit 0069a73
Showing
1 changed file
with
37 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
# VERCEL | ||
|
||
To deploy my repository in Vercel I stuck to the [official documentation](https://vercel.com/docs/platform/deployments). | ||
|
||
First you have to athorize Vercel to access your GitHub account then you choose which project you want to import | ||
|
||
 | ||
|
||
Then we can choose which folders we want to import. It may looks like choosing everything is not the best choice but the functions probably need to access others directories. | ||
|
||
Finally, in order to make the deployment: | ||
|
||
- To make a deplyment preview: | ||
~~~ | ||
$ vercel | ||
~~~ | ||
|
||
- To make a production deployment_ | ||
~~~ | ||
$ vercel --prod | ||
~~~ | ||
|
||
Now with every push to my repository Vercel is going to be launch aswell | ||
|
||
## Creating a function | ||
|
||
Vercel builds functions within the '/api' directory.To work it must export a default function handler. | ||
|
||
I'm going to implement a function to see which item is the cheaper one.It is user story 6. | ||
|
||
|
||
 | ||
|
||
The function Price gets every price of the data and it save the lower price. It is a very simple function that works fine. | ||
|
||
|
||
Additionally I have created a file with the [data](https://github.com/miguelfdez99/MyOutlet/blob/master/api/data.js) |