...
/Building the UI for Product API: Adding a Product
Building the UI for Product API: Adding a Product
Learn how to add a new product on the page.
We'll cover the following...
We'll cover the following...
Delete the “About” page
We won’t be using the “About” page, so let’s delete the About.vue
file and router code.
{path: "/about",name: "About",// route level code-splitting// this generates a separate chunk (about.[hash].js) for this route// which is lazy-loaded when the route is visited.component: () =>import(/* webpackChunkName: "about" */ "../views/About.vue"),}
Create the template
Let’s create a file called AddProduct.vue
with a container
class. It has two properties, baseURL
and categories
. We’ll have a dropdown to select which category to add the product to.
We’ll have five variables that are required to ...