Skip to content

Instantly share code, notes, and snippets.

@VitorTheGreat
Last active December 15, 2022 16:51
Show Gist options
  • Save VitorTheGreat/a42ff6eff009d04b44da6a816e7a436b to your computer and use it in GitHub Desktop.
Save VitorTheGreat/a42ff6eff009d04b44da6a816e7a436b to your computer and use it in GitHub Desktop.
Vtex IO Start (Basics)

Vtex IO Start Tutorial

  1. Clone project from bitBucket

    git clone HTTP 
    
  2. Install Vtex

    npm i -g vtex 
    yarn add global vtex
    

    2.1. Update vtex when asked (keep using the PM you started the project

    npm i -g vtex
    yarn add global vtex
    

    2.2 Start a project with vtex (only once)

    vtex init 
    
  3. Log in to the account

    vtex login -a <STORE_ACCOUNT>  #(e.g. vtex login -a rapsodiaar) 
    
    • obs: It will open a browser window to log into vtex
  4. Install packages in order that the store works properly

    vtex install vtex.store-sitemap
    vtex install vtex.store
    vtex install vtex.admin
    vtex install vtex.admin-pages 
    
  5. Change to/Create your workspace

    vtex use <WORKSPACE> #(e.g. vtex use devvitor)
    
    • obs: When creating vtex will ask you.

    5.1 * Reseting your workspace

    vtex workspace reset <WORKSPACE> 
    
  6. Check if it is everything ok and you are logged in

    vtex whoam i 
    
  7. Link your branch to your workspace to work

    vtex link --verbose 
    

    -obs: Look at the terminal to see if it is successfully linked

  8. Access your workspace in the browser

  9. Be happy and start building something amazing!

BONUS: In development, pass the parameter ?__inspect=true to the URL so you can inspect the blocks

Found any errors? be free to correct and warn me, please: vitor.services@gmail.com

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment